├── .qmake.conf
├── .tag
├── LICENSE.GPL2
├── LICENSE.GPL3
├── LICENSE.GPL3-EXCEPT
├── LICENSE.LGPL3
├── dist
├── changes-5.10.0
├── changes-5.10.1
├── changes-5.11.0
├── changes-5.11.1
├── changes-5.11.2
├── changes-5.11.3
├── changes-5.12.0
├── changes-5.6.2
├── changes-5.6.3
├── changes-5.7.0
├── changes-5.8.0
├── changes-5.9.0
├── changes-5.9.1
├── changes-5.9.2
├── changes-5.9.3
├── changes-5.9.4
├── changes-5.9.5
└── changes-5.9.6
├── examples
├── canvas3d
│ ├── 3rdparty
│ │ ├── ThreeJSLoader.js
│ │ ├── gl-matrix.js
│ │ ├── three.js
│ │ └── threex.planets.js
│ ├── canvas3d.pro
│ ├── framebuffer
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── framebuffer-example.png
│ │ │ └── src
│ │ │ │ └── framebuffer.qdoc
│ │ ├── framebuffer.pro
│ │ ├── framebuffer.qrc
│ │ ├── main.cpp
│ │ └── qml
│ │ │ └── framebuffer
│ │ │ ├── framebuffer.js
│ │ │ ├── main.qml
│ │ │ └── qtlogo.png
│ ├── interaction
│ │ ├── 3dmodels.txt
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── interaction-example.png
│ │ │ └── src
│ │ │ │ └── interaction.qdoc
│ │ ├── interaction.pro
│ │ ├── interaction.qrc
│ │ ├── main.cpp
│ │ ├── qml
│ │ │ └── interaction
│ │ │ │ ├── barrel.jpg
│ │ │ │ ├── barrel.json
│ │ │ │ ├── interaction.js
│ │ │ │ └── main.qml
│ │ └── readme.txt
│ ├── jsonmodels
│ │ ├── 3dmodels.txt
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── jsonmodels-example.png
│ │ │ └── src
│ │ │ │ └── jsonmodels.qdoc
│ │ ├── jsonmodels.pro
│ │ ├── main.cpp
│ │ ├── qml.qrc
│ │ ├── qml
│ │ │ └── jsonmodels
│ │ │ │ ├── bush.json
│ │ │ │ ├── bush.png
│ │ │ │ ├── gold.jpg
│ │ │ │ ├── gold.json
│ │ │ │ ├── jsonmodels.js
│ │ │ │ ├── jsonmodels.qml
│ │ │ │ ├── pallet.jpg
│ │ │ │ ├── pallet.json
│ │ │ │ ├── rock.jpg
│ │ │ │ ├── rock.json
│ │ │ │ ├── woodbox.jpg
│ │ │ │ └── woodbox.json
│ │ └── readme.txt
│ ├── quickitemtexture
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── quickitemtexture-example.png
│ │ │ └── src
│ │ │ │ └── quickitemtexture.qdoc
│ │ ├── main.cpp
│ │ ├── qml
│ │ │ └── quickitemtexture
│ │ │ │ ├── main.qml
│ │ │ │ └── quickitemtexture.js
│ │ ├── quickitemtexture.pro
│ │ └── quickitemtexture.qrc
│ ├── textureandlight
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── textureandlight-example.png
│ │ │ └── src
│ │ │ │ └── textureandlight.qdoc
│ │ ├── main.cpp
│ │ ├── qml
│ │ │ └── textureandlight
│ │ │ │ ├── main.qml
│ │ │ │ ├── qtlogo.png
│ │ │ │ └── textureandlight.js
│ │ ├── textureandlight.pro
│ │ └── textureandlight.qrc
│ └── threejs
│ │ ├── cellphone
│ │ ├── cellphone.pro
│ │ ├── cellphone.qrc
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── cellphone-example.png
│ │ │ └── src
│ │ │ │ └── cellphone.qdoc
│ │ ├── images
│ │ │ ├── calendar.png
│ │ │ ├── camera.png
│ │ │ ├── clock.png
│ │ │ ├── contacts.png
│ │ │ ├── gallery.png
│ │ │ ├── games.png
│ │ │ ├── lock.png
│ │ │ ├── mail.png
│ │ │ ├── maps.png
│ │ │ ├── menu_background.jpg
│ │ │ ├── music.png
│ │ │ ├── plutomap1k.jpg
│ │ │ ├── qtlogo_with_alpha.png
│ │ │ ├── settings.png
│ │ │ ├── todo.png
│ │ │ └── videos.png
│ │ ├── main.cpp
│ │ └── qml
│ │ │ └── cellphone
│ │ │ ├── cellphone.js
│ │ │ ├── cellphone_case.json
│ │ │ ├── cellphone_front.json
│ │ │ ├── cellphone_icon.json
│ │ │ ├── cellphoneapp.qml
│ │ │ ├── cellphonecanvas.qml
│ │ │ ├── colorselector.qml
│ │ │ ├── fpsdisplay.qml
│ │ │ └── main.qml
│ │ ├── controls
│ │ └── ControlEventSource.qml
│ │ ├── oneqt
│ │ ├── ImageCube.qml
│ │ ├── InfoSheet.qml
│ │ ├── Navibutton.qml
│ │ ├── SwipeArea.qml
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── oneqt-example.png
│ │ │ └── src
│ │ │ │ └── oneqt.qdoc
│ │ ├── imagecube.js
│ │ ├── ios
│ │ │ ├── Info.plist
│ │ │ ├── OneQtIcon29x29.png
│ │ │ ├── OneQtIcon29x29@2x.png
│ │ │ ├── OneQtIcon29x29@2x~ipad.png
│ │ │ ├── OneQtIcon29x29~ipad.png
│ │ │ ├── OneQtIcon40x40@2x.png
│ │ │ ├── OneQtIcon40x40@2x~ipad.png
│ │ │ ├── OneQtIcon40x40~ipad.png
│ │ │ ├── OneQtIcon50x50@2x~ipad.png
│ │ │ ├── OneQtIcon50x50~ipad.png
│ │ │ ├── OneQtIcon57x57.png
│ │ │ ├── OneQtIcon57x57@2x.png
│ │ │ ├── OneQtIcon60x60@2x.png
│ │ │ ├── OneQtIcon72x72@2x~ipad.png
│ │ │ ├── OneQtIcon72x72~ipad.png
│ │ │ ├── OneQtIcon76x76@2x~ipad.png
│ │ │ └── OneQtIcon76x76~ipad.png
│ │ ├── main.cpp
│ │ ├── oneqt.pro
│ │ ├── oneqt.qml
│ │ ├── oneqt.qrc
│ │ └── textures
│ │ │ ├── dataviz.jpg
│ │ │ ├── devices.png
│ │ │ ├── embedded.png
│ │ │ ├── iot.png
│ │ │ ├── multiscreen.png
│ │ │ ├── puzzle-pieces.png
│ │ │ ├── qtlogo.png
│ │ │ └── qtlogosmall.png
│ │ ├── planets
│ │ ├── FpsDisplay.qml
│ │ ├── InfoSheet.qml
│ │ ├── PlanetButton.qml
│ │ ├── StyledSlider.qml
│ │ ├── doc
│ │ │ ├── images
│ │ │ │ └── planets-example.jpg
│ │ │ └── src
│ │ │ │ └── planets.qdoc
│ │ ├── images
│ │ │ ├── earth.png
│ │ │ ├── earthbump1k.jpg
│ │ │ ├── earthcloudmapcolortrans.png
│ │ │ ├── earthmap1k.jpg
│ │ │ ├── earthspec1k.jpg
│ │ │ ├── galaxy_starfield.png
│ │ │ ├── jupiter.png
│ │ │ ├── jupitermap.jpg
│ │ │ ├── mars.png
│ │ │ ├── marsbump1k.jpg
│ │ │ ├── marsmap1k.jpg
│ │ │ ├── mercury.png
│ │ │ ├── mercurybump.jpg
│ │ │ ├── mercurymap.jpg
│ │ │ ├── moonbump1k.jpg
│ │ │ ├── moonmap1k.jpg
│ │ │ ├── neptune.png
│ │ │ ├── neptunemap.jpg
│ │ │ ├── plutobump1k.jpg
│ │ │ ├── plutomap1k.jpg
│ │ │ ├── saturn.png
│ │ │ ├── saturnmap.jpg
│ │ │ ├── saturnringcolortrans.png
│ │ │ ├── sun.png
│ │ │ ├── sunmap.jpg
│ │ │ ├── uranus.png
│ │ │ ├── uranusmap.jpg
│ │ │ ├── uranusringcolortrans.png
│ │ │ ├── venus.png
│ │ │ ├── venusbump.jpg
│ │ │ └── venusmap.jpg
│ │ ├── ios
│ │ │ ├── AppIcon29x29.png
│ │ │ ├── AppIcon29x29@2x.png
│ │ │ ├── AppIcon29x29@2x~ipad.png
│ │ │ ├── AppIcon29x29~ipad.png
│ │ │ ├── AppIcon40x40@2x.png
│ │ │ ├── AppIcon40x40@2x~ipad.png
│ │ │ ├── AppIcon40x40~ipad.png
│ │ │ ├── AppIcon50x50@2x~ipad.png
│ │ │ ├── AppIcon50x50~ipad.png
│ │ │ ├── AppIcon57x57.png
│ │ │ ├── AppIcon57x57@2x.png
│ │ │ ├── AppIcon60x60@2x.png
│ │ │ ├── AppIcon72x72@2x~ipad.png
│ │ │ ├── AppIcon72x72~ipad.png
│ │ │ ├── AppIcon76x76@2x~ipad.png
│ │ │ ├── AppIcon76x76~ipad.png
│ │ │ └── Info.plist
│ │ ├── main.cpp
│ │ ├── planets.js
│ │ ├── planets.pro
│ │ ├── planets.qml
│ │ └── planets.qrc
│ │ └── threejs.pro
└── examples.pro
├── qtcanvas3d.pro
├── src
├── imports
│ ├── imports.pro
│ └── qtcanvas3d
│ │ ├── abstractobject3d.cpp
│ │ ├── abstractobject3d_p.h
│ │ ├── activeinfo3d.cpp
│ │ ├── activeinfo3d_p.h
│ │ ├── arrayutils.cpp
│ │ ├── arrayutils_p.h
│ │ ├── buffer3d.cpp
│ │ ├── buffer3d_p.h
│ │ ├── canvas3d.cpp
│ │ ├── canvas3d_p.h
│ │ ├── canvas3dcommon_p.h
│ │ ├── canvasglstatedump.cpp
│ │ ├── canvasglstatedump_p.h
│ │ ├── canvasrenderer.cpp
│ │ ├── canvasrenderer_p.h
│ │ ├── canvasrendernode.cpp
│ │ ├── canvasrendernode_p.h
│ │ ├── canvastextureprovider.cpp
│ │ ├── canvastextureprovider_p.h
│ │ ├── compressedtexturepvrtc.cpp
│ │ ├── compressedtexturepvrtc_p.h
│ │ ├── compressedtextures3tc.cpp
│ │ ├── compressedtextures3tc_p.h
│ │ ├── context3d.cpp
│ │ ├── context3d_p.h
│ │ ├── contextattributes.cpp
│ │ ├── contextattributes_p.h
│ │ ├── doc
│ │ ├── QtCanvas3D
│ │ ├── qtcanvas3d.qdocconf
│ │ ├── snippets
│ │ │ ├── doc_src_qtcanvas3d.cpp
│ │ │ └── doc_src_qtcanvas3d.pro
│ │ └── src
│ │ │ ├── qtcanvas3d-index.qdoc
│ │ │ └── qtcanvas3d.qdoc
│ │ ├── enumtostringmap.cpp
│ │ ├── enumtostringmap_p.h
│ │ ├── framebuffer3d.cpp
│ │ ├── framebuffer3d_p.h
│ │ ├── glcommandqueue.cpp
│ │ ├── glcommandqueue_p.h
│ │ ├── glstatestore.cpp
│ │ ├── glstatestore_p.h
│ │ ├── openglversionchecker.cpp
│ │ ├── openglversionchecker_p.h
│ │ ├── plugins.qmltypes
│ │ ├── program3d.cpp
│ │ ├── program3d_p.h
│ │ ├── qcanvas3d_plugin.cpp
│ │ ├── qcanvas3d_plugin.h
│ │ ├── qmldir
│ │ ├── qtcanvas3d.pro
│ │ ├── renderbuffer3d.cpp
│ │ ├── renderbuffer3d_p.h
│ │ ├── renderjob.cpp
│ │ ├── renderjob_p.h
│ │ ├── shader3d.cpp
│ │ ├── shader3d_p.h
│ │ ├── shaderprecisionformat.cpp
│ │ ├── shaderprecisionformat_p.h
│ │ ├── teximage3d.cpp
│ │ ├── teximage3d_p.h
│ │ ├── texture3d.cpp
│ │ ├── texture3d_p.h
│ │ ├── uniformlocation.cpp
│ │ └── uniformlocation_p.h
└── src.pro
├── sync.profile
└── tests
├── auto
├── auto.pro
└── qmltest
│ ├── canvas3d
│ ├── tst_attribs.js
│ ├── tst_attribs.qml
│ ├── tst_creation_aa_context.qml
│ ├── tst_creation_depth_context.qml
│ ├── tst_creation_empty.qml
│ ├── tst_program.js
│ ├── tst_program.qml
│ ├── tst_quick_item_as_texture.js
│ ├── tst_quick_item_as_texture.qml
│ ├── tst_render_checkresult.js
│ ├── tst_render_checkresult.png
│ ├── tst_render_checkresult.qml
│ ├── tst_render_dynamic.qml
│ ├── tst_render_dynamic_canvas_component.qml
│ ├── tst_render_ondemand.js
│ ├── tst_render_ondemand.qml
│ ├── tst_render_premultipliedalpha.js
│ ├── tst_render_premultipliedalpha.qml
│ ├── tst_render_preserve.js
│ ├── tst_render_preserve.qml
│ ├── tst_render_simple.js
│ ├── tst_render_simple.qml
│ ├── tst_render_target.js
│ ├── tst_render_target.qml
│ ├── tst_uniforms.js
│ └── tst_uniforms.qml
│ ├── qmltest.pro
│ └── tst_qmltest.cpp
├── manual
├── commandthroughput
│ ├── commandthroughput.pro
│ ├── commandthroughput.qrc
│ ├── main.cpp
│ └── qml
│ │ └── commandthroughput
│ │ ├── commandthroughput.js
│ │ └── main.qml
├── manual.pro
└── multiwindowtest
│ ├── main.cpp
│ ├── multiwindowtest.pro
│ ├── multiwindowtest.qrc
│ └── qml
│ └── multiwindowtest
│ ├── canvaswindow.qml
│ ├── framebuffer.js
│ ├── framebuffer.qml
│ ├── main.qml
│ ├── multiwindowtest.js
│ ├── qtlogo.png
│ ├── quickitemtexture.js
│ └── quickitemtexture.qml
└── tests.pro
/.qmake.conf:
--------------------------------------------------------------------------------
1 | load(qt_build_config)
2 | CONFIG += warning_clean
3 | DEFINES += QT_NO_FOREACH
4 |
5 | MODULE_VERSION = 5.13.0
6 |
7 | CMAKE_MODULE_TESTS=-
8 |
--------------------------------------------------------------------------------
/.tag:
--------------------------------------------------------------------------------
1 | 433633fb7285087724d39249060ca10c1dfea9a1
2 |
--------------------------------------------------------------------------------
/dist/changes-5.10.0:
--------------------------------------------------------------------------------
1 | Qt 5.10 introduces many new features and improvements as well as bugfixes
2 | over the 5.9.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | http://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.10 series is binary compatible with the 5.10.x series.
8 | Applications compiled for 5.9 will continue to run with 5.10.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
18 | ****************************************************************************
19 | * Qt 5.10.0 Changes *
20 | ****************************************************************************
21 |
22 | - This release contains only minor code improvements.
23 |
--------------------------------------------------------------------------------
/dist/changes-5.10.1:
--------------------------------------------------------------------------------
1 | Qt 5.10.1 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.10.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.10 series is binary compatible with the 5.9.x series.
10 | Applications compiled for 5.9 will continue to run with 5.10.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | This release contains all fixes included in the Qt 5.9.4 release.
21 |
22 | ****************************************************************************
23 | * Qt 5.10.1 Changes *
24 | ****************************************************************************
25 |
26 | - This release contains only minor code improvements.
27 |
--------------------------------------------------------------------------------
/dist/changes-5.11.0:
--------------------------------------------------------------------------------
1 | Qt 5.11 introduces many new features and improvements as well as bugfixes
2 | over the 5.10.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | http://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.11 series is binary compatible with the 5.10.x series.
8 | Applications compiled for 5.10 will continue to run with 5.11.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
18 | ****************************************************************************
19 | * Qt 5.11.0 Changes *
20 | ****************************************************************************
21 |
22 | - This release contains only minor code improvements.
23 |
--------------------------------------------------------------------------------
/dist/changes-5.11.1:
--------------------------------------------------------------------------------
1 | Qt 5.11.1 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.11.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.11 series is binary compatible with the 5.10.x series.
10 | Applications compiled for 5.10 will continue to run with 5.11.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.11.1 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.11.2:
--------------------------------------------------------------------------------
1 | Qt 5.11.2 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.11.0 through 5.11.1.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.11 series is binary compatible with the 5.10.x series.
10 | Applications compiled for 5.10 will continue to run with 5.11.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.11.2 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.11.3:
--------------------------------------------------------------------------------
1 | Qt 5.11.3 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.11.0 through 5.11.2.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.11 series is binary compatible with the 5.10.x series.
10 | Applications compiled for 5.10 will continue to run with 5.11.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | - This release contains only minor code improvements.
21 |
--------------------------------------------------------------------------------
/dist/changes-5.12.0:
--------------------------------------------------------------------------------
1 | Qt 5.12 introduces many new features and improvements as well as bugfixes
2 | over the 5.11.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | https://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.12 series is binary compatible with the 5.11.x series.
8 | Applications compiled for 5.11 will continue to run with 5.12.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
18 | ****************************************************************************
19 | * QtCanvas3D *
20 | ****************************************************************************
21 |
22 | - Important Behavior Changes:
23 | * [QTBUG-70510] Canvas3D module and API deprecated.
24 |
--------------------------------------------------------------------------------
/dist/changes-5.6.2:
--------------------------------------------------------------------------------
1 | Qt 5.6.2 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.6.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.6 series is binary compatible with the 5.5.x series.
10 | Applications compiled for 5.5 will continue to run with 5.6.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | Fixes
21 | -----
22 |
23 | - [QTBUG-54466] Check for null context in CanvasRenderJob.
24 | - [QTBUG-54876] Align pixel-row of the image passed to glTexImage2D to UNPACK_ALIGN.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.6.3:
--------------------------------------------------------------------------------
1 | Qt 5.6.3 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.6.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.6 series is binary compatible with the 5.5.x series.
10 | Applications compiled for 5.5 will continue to run with 5.6.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Library *
22 | ****************************************************************************
23 |
24 | - [QTBUG-56673] CanvasRenderer: Improve software opengl renderer detection.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.7.0:
--------------------------------------------------------------------------------
1 | Qt 5.7 introduces many new features and improvements as well as bugfixes
2 | over the 5.6.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | http://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.7 series is binary compatible with the 5.6.x series.
8 | Applications compiled for 5.6 will continue to run with 5.7.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
18 | ****************************************************************************
19 | * Library *
20 | ****************************************************************************
21 |
22 | - Fixed issues with building canvas statically.
23 |
24 | ****************************************************************************
25 | * Examples *
26 | ****************************************************************************
27 |
28 | - Three.js port included in examples was updated to r74.
29 |
--------------------------------------------------------------------------------
/dist/changes-5.8.0:
--------------------------------------------------------------------------------
1 | Qt 5.8 introduces many new features and improvements as well as bugfixes
2 | over the 5.7.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | http://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.8 series is binary compatible with the 5.7.x series.
8 | Applications compiled for 5.7 will continue to run with 5.8.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
18 | ****************************************************************************
19 | * Library *
20 | ****************************************************************************
21 |
22 | - [QTBUG-54466] Fix crash when QOpenGLContext::currentContext() is NULL.
23 | - [QTBUG-54876] Aligned pixel-row of the image passed to glTexImage2D to
24 | UNPACK_ALIGN.
25 | - [QTBUG-56673] Improved software opengl renderer detection.
26 | - Fixed quadratic loop in CanvasTextureImageFactory.
27 |
28 | ****************************************************************************
29 | * Examples *
30 | ****************************************************************************
31 |
32 | - [QTBUG-50393] Fix cellphone example flicking
33 |
--------------------------------------------------------------------------------
/dist/changes-5.9.0:
--------------------------------------------------------------------------------
1 | Qt 5.9 introduces many new features and improvements as well as bugfixes
2 | over the 5.8.x series. For more details, refer to the online documentation
3 | included in this distribution. The documentation is also available online:
4 |
5 | http://doc.qt.io/qt-5/index.html
6 |
7 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
8 | Applications compiled for 5.8 will continue to run with 5.9.
9 |
10 | Some of the changes listed in this file include issue tracking numbers
11 | corresponding to tasks in the Qt Bug Tracker:
12 |
13 | https://bugreports.qt.io/
14 |
15 | Each of these identifiers can be entered in the bug tracker to obtain more
16 | information about a particular change.
17 |
--------------------------------------------------------------------------------
/dist/changes-5.9.1:
--------------------------------------------------------------------------------
1 | Qt 5.9.1 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.1 Changes *
22 | ****************************************************************************
23 |
24 | - No significant changes
25 |
--------------------------------------------------------------------------------
/dist/changes-5.9.2:
--------------------------------------------------------------------------------
1 | Qt 5.9.2 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.2 Changes *
22 | ****************************************************************************
23 |
24 | - No significant changes
25 |
--------------------------------------------------------------------------------
/dist/changes-5.9.3:
--------------------------------------------------------------------------------
1 | Qt 5.9.3 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.3 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.9.4:
--------------------------------------------------------------------------------
1 | Qt 5.9.4 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.4 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
26 |
--------------------------------------------------------------------------------
/dist/changes-5.9.5:
--------------------------------------------------------------------------------
1 | Qt 5.9.5 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.5 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
--------------------------------------------------------------------------------
/dist/changes-5.9.6:
--------------------------------------------------------------------------------
1 | Qt 5.9.6 is a bug-fix release. It maintains both forward and backward
2 | compatibility (source and binary) with Qt 5.9.0 through 5.9.5.
3 |
4 | For more details, refer to the online documentation included in this
5 | distribution. The documentation is also available online:
6 |
7 | http://doc.qt.io/qt-5/index.html
8 |
9 | The Qt version 5.9 series is binary compatible with the 5.8.x series.
10 | Applications compiled for 5.8 will continue to run with 5.9.
11 |
12 | Some of the changes listed in this file include issue tracking numbers
13 | corresponding to tasks in the Qt Bug Tracker:
14 |
15 | https://bugreports.qt.io/
16 |
17 | Each of these identifiers can be entered in the bug tracker to obtain more
18 | information about a particular change.
19 |
20 | ****************************************************************************
21 | * Qt 5.9.6 Changes *
22 | ****************************************************************************
23 |
24 | - This release contains only minor code improvements.
25 |
--------------------------------------------------------------------------------
/examples/canvas3d/canvas3d.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | SUBDIRS += textureandlight \
3 | framebuffer \
4 | interaction \
5 | jsonmodels \
6 | quickitemtexture \
7 | threejs
8 |
9 | OTHER_FILES += 3rdparty/*
10 |
11 | EXAMPLE_FILES = 3rdparty
12 |
--------------------------------------------------------------------------------
/examples/canvas3d/framebuffer/doc/images/framebuffer-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/framebuffer/doc/images/framebuffer-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/framebuffer/framebuffer.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | RESOURCES += framebuffer.qrc
11 |
12 | OTHER_FILES += qml/framebuffer/* \
13 | doc/src/* \
14 | doc/images/*
15 |
16 |
--------------------------------------------------------------------------------
/examples/canvas3d/framebuffer/framebuffer.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../3rdparty/gl-matrix.js
4 | qml/framebuffer/main.qml
5 | qml/framebuffer/qtlogo.png
6 | qml/framebuffer/framebuffer.js
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/canvas3d/framebuffer/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 | #include
54 | #include
55 |
56 | int main(int argc, char *argv[])
57 | {
58 | QGuiApplication app(argc, argv);
59 |
60 | QQuickView viewer;
61 |
62 | // The following are needed to make examples run without having to install the module
63 | // in desktop environments.
64 | #ifdef Q_OS_WIN
65 | QString extraImportPath(QStringLiteral("%1/../../../../%2"));
66 | #else
67 | QString extraImportPath(QStringLiteral("%1/../../../%2"));
68 | #endif
69 | viewer.engine()->addImportPath(extraImportPath.arg(QGuiApplication::applicationDirPath(),
70 | QString::fromLatin1("qml")));
71 |
72 | viewer.setSource(QUrl(QStringLiteral("qrc:/main.qml")));
73 |
74 | viewer.setTitle(QStringLiteral("Render into FrameBuffer"));
75 | viewer.setResizeMode(QQuickView::SizeRootObjectToView);
76 | viewer.setColor(QColor(0xf2, 0xf2, 0xf2));
77 | viewer.show();
78 |
79 | return app.exec();
80 | }
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/framebuffer/qml/framebuffer/qtlogo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/framebuffer/qml/framebuffer/qtlogo.png
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/3dmodels.txt:
--------------------------------------------------------------------------------
1 | Provided by Nobiax.
2 |
3 | CC0 1.0 Universal (CC0 1.0)
4 | Public Domain Dedication
5 | No Copyright
6 | This license is acceptable for Free Cultural Works
7 |
8 | The person who associated a work with this deed has dedicated the work to the public domain by waiving all of his or her rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law.
9 |
10 | You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.
11 |
12 | So absolutely free to use or to modify in any kind of work (personal, commercial or else) =)
13 |
14 | Please (no obligation), send me a link of the result at nobiax.deviantart.com or my other account on OpenGameArt.com (yughues) or ShareCG.com (yughues)
15 | ( watch my journal on deviantart to find them ) ;)
16 |
17 | Or on Youtube.
18 |
19 | For any commissions details are on my DeviantArt account.
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/doc/images/interaction-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/interaction/doc/images/interaction-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/interaction.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | OTHER_FILES += qml/interaction/* \
11 | doc/src/* \
12 | doc/images/*
13 |
14 | RESOURCES += interaction.qrc
15 |
16 | EXAMPLE_FILES += \
17 | 3dmodels.txt \
18 | readme.txt
19 |
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/interaction.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../3rdparty/gl-matrix.js
4 | ../3rdparty/ThreeJSLoader.js
5 | qml/interaction/barrel.jpg
6 | qml/interaction/barrel.json
7 | qml/interaction/main.qml
8 | qml/interaction/interaction.js
9 |
10 |
11 |
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 | #include
54 | #include
55 |
56 | int main(int argc, char *argv[])
57 | {
58 | QGuiApplication app(argc, argv);
59 |
60 | QQuickView viewer;
61 |
62 | // The following are needed to make examples run without having to install the module
63 | // in desktop environments.
64 | #ifdef Q_OS_WIN
65 | QString extraImportPath(QStringLiteral("%1/../../../../%2"));
66 | #else
67 | QString extraImportPath(QStringLiteral("%1/../../../%2"));
68 | #endif
69 | viewer.engine()->addImportPath(extraImportPath.arg(QGuiApplication::applicationDirPath(),
70 | QString::fromLatin1("qml")));
71 |
72 | viewer.setSource(QUrl("qrc:/main.qml"));
73 |
74 | viewer.setTitle(QStringLiteral("Interaction"));
75 | viewer.setResizeMode(QQuickView::SizeRootObjectToView);
76 | viewer.setColor(QColor(0xfa, 0xfa, 0xfa));
77 | viewer.show();
78 |
79 | return app.exec();
80 | }
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/qml/interaction/barrel.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/interaction/qml/interaction/barrel.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/interaction/readme.txt:
--------------------------------------------------------------------------------
1 | 3D Models and textures used in the example courtesy of http://nobiax.deviantart.com/
2 |
3 | See 3dmodels.txt for more information about the models.
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/3dmodels.txt:
--------------------------------------------------------------------------------
1 | Provided by Nobiax.
2 |
3 | CC0 1.0 Universal (CC0 1.0)
4 | Public Domain Dedication
5 | No Copyright
6 | This license is acceptable for Free Cultural Works
7 |
8 | The person who associated a work with this deed has dedicated the work to the public domain by waiving all of his or her rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law.
9 |
10 | You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.
11 |
12 | So absolutely free to use or to modify in any kind of work (personal, commercial or else) =)
13 |
14 | Please (no obligation), send me a link of the result at nobiax.deviantart.com or my other account on OpenGameArt.com (yughues) or ShareCG.com (yughues)
15 | ( watch my journal on deviantart to find them ) ;)
16 |
17 | Or on Youtube.
18 |
19 | For any commissions details are on my DeviantArt account.
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/doc/images/jsonmodels-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/doc/images/jsonmodels-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/jsonmodels.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | RESOURCES += qml.qrc
11 |
12 | OTHER_FILES += doc/src/* \
13 | doc/images/*
14 |
15 | EXAMPLE_FILES += \
16 | 3dmodels.txt \
17 | readme.txt
18 |
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 |
54 | int main(int argc, char *argv[])
55 | {
56 | QGuiApplication app(argc, argv);
57 |
58 | QQmlApplicationEngine engine;
59 | engine.load(QUrl(QStringLiteral("qrc:/jsonmodels.qml")));
60 |
61 | return app.exec();
62 | }
63 |
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../3rdparty/gl-matrix.js
4 | ../3rdparty/ThreeJSLoader.js
5 | qml/jsonmodels/bush.json
6 | qml/jsonmodels/bush.png
7 | qml/jsonmodels/gold.jpg
8 | qml/jsonmodels/gold.json
9 | qml/jsonmodels/jsonmodels.js
10 | qml/jsonmodels/jsonmodels.qml
11 | qml/jsonmodels/pallet.jpg
12 | qml/jsonmodels/pallet.json
13 | qml/jsonmodels/rock.jpg
14 | qml/jsonmodels/rock.json
15 | qml/jsonmodels/woodbox.jpg
16 | qml/jsonmodels/woodbox.json
17 |
18 |
19 |
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml/jsonmodels/bush.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/qml/jsonmodels/bush.png
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml/jsonmodels/gold.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/qml/jsonmodels/gold.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml/jsonmodels/pallet.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/qml/jsonmodels/pallet.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml/jsonmodels/rock.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/qml/jsonmodels/rock.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/qml/jsonmodels/woodbox.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/jsonmodels/qml/jsonmodels/woodbox.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/jsonmodels/readme.txt:
--------------------------------------------------------------------------------
1 | 3D Models and textures used in the example courtesy of http://nobiax.deviantart.com/
2 |
3 | See 3dmodels.txt for more information about the models.
--------------------------------------------------------------------------------
/examples/canvas3d/quickitemtexture/doc/images/quickitemtexture-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/quickitemtexture/doc/images/quickitemtexture-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/quickitemtexture/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 |
54 | int main(int argc, char *argv[])
55 | {
56 | QGuiApplication app(argc, argv);
57 |
58 | QQmlApplicationEngine engine;
59 |
60 | engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
61 |
62 | return app.exec();
63 | }
64 |
--------------------------------------------------------------------------------
/examples/canvas3d/quickitemtexture/quickitemtexture.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | RESOURCES += quickitemtexture.qrc
11 |
12 | OTHER_FILES += qml/quickitemtexture/* \
13 | doc/src/* \
14 | doc/images/*
15 |
16 |
--------------------------------------------------------------------------------
/examples/canvas3d/quickitemtexture/quickitemtexture.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../3rdparty/gl-matrix.js
4 | qml/quickitemtexture/main.qml
5 | qml/quickitemtexture/quickitemtexture.js
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/canvas3d/textureandlight/doc/images/textureandlight-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/textureandlight/doc/images/textureandlight-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/textureandlight/qml/textureandlight/qtlogo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/textureandlight/qml/textureandlight/qtlogo.png
--------------------------------------------------------------------------------
/examples/canvas3d/textureandlight/textureandlight.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | RESOURCES += textureandlight.qrc
11 |
12 | OTHER_FILES += qml/textureandlight/* \
13 | doc/src/* \
14 | doc/images/*
15 |
16 |
--------------------------------------------------------------------------------
/examples/canvas3d/textureandlight/textureandlight.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | qml/textureandlight/main.qml
4 | qml/textureandlight/textureandlight.js
5 | qml/textureandlight/qtlogo.png
6 | ../3rdparty/gl-matrix.js
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/cellphone.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/threejs/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | RESOURCES += cellphone.qrc
11 |
12 | OTHER_FILES += qml/cellphone/* \
13 | doc/src/* \
14 | doc/images/*
15 |
16 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/cellphone.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../../3rdparty/three.js
4 | qml/cellphone/main.qml
5 | qml/cellphone/cellphoneapp.qml
6 | qml/cellphone/cellphonecanvas.qml
7 | qml/cellphone/colorselector.qml
8 | qml/cellphone/fpsdisplay.qml
9 | qml/cellphone/cellphone.js
10 | qml/cellphone/cellphone_case.json
11 | qml/cellphone/cellphone_front.json
12 | qml/cellphone/cellphone_icon.json
13 | images/menu_background.jpg
14 | images/plutomap1k.jpg
15 | images/qtlogo_with_alpha.png
16 | images/calendar.png
17 | images/camera.png
18 | images/clock.png
19 | images/contacts.png
20 | images/gallery.png
21 | images/games.png
22 | images/lock.png
23 | images/mail.png
24 | images/maps.png
25 | images/music.png
26 | images/settings.png
27 | images/todo.png
28 | images/videos.png
29 |
30 |
31 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/doc/images/cellphone-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/doc/images/cellphone-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/calendar.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/calendar.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/camera.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/camera.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/clock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/clock.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/contacts.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/contacts.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/gallery.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/gallery.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/games.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/games.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/lock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/lock.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/mail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/mail.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/maps.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/maps.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/menu_background.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/menu_background.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/music.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/music.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/plutomap1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/plutomap1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/qtlogo_with_alpha.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/qtlogo_with_alpha.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/settings.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/todo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/todo.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/images/videos.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/cellphone/images/videos.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 |
54 | int main(int argc, char *argv[])
55 | {
56 | QGuiApplication app(argc, argv);
57 |
58 | QQmlApplicationEngine engine;
59 |
60 | engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
61 |
62 | return app.exec();
63 | }
64 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/qml/cellphone/cellphone_front.json:
--------------------------------------------------------------------------------
1 | {
2 |
3 | "metadata" :
4 | {
5 | "formatVersion" : 3.1,
6 | "sourceFile" : "cellphone_front.obj",
7 | "generatedBy" : "OBJConverter",
8 | "vertices" : 4,
9 | "faces" : 1,
10 | "normals" : 1,
11 | "colors" : 0,
12 | "uvs" : 4,
13 | "materials" : 0
14 | },
15 |
16 | "scale" : 1.000000,
17 |
18 | "materials": [],
19 |
20 | "vertices": [0.475000,0.025000,-0.974999,0.474999,0.025000,0.975000,-0.475000,0.025000,0.974999,-0.475000,0.025000,-0.975000],
21 |
22 | "morphTargets": [],
23 |
24 | "morphColors": [],
25 |
26 | "normals": [0,1,0],
27 |
28 | "colors": [],
29 |
30 | "uvs": [[0,0,1,0,1,1,0,1]],
31 |
32 | "faces": [43,0,3,2,1,0,0,1,2,3,0,0,0,0]
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/cellphone/qml/cellphone/cellphone_icon.json:
--------------------------------------------------------------------------------
1 | {
2 |
3 | "metadata" :
4 | {
5 | "formatVersion" : 3.1,
6 | "sourceFile" : "cellphone_icon.obj",
7 | "generatedBy" : "OBJConverter",
8 | "vertices" : 4,
9 | "faces" : 2,
10 | "normals" : 1,
11 | "colors" : 0,
12 | "uvs" : 4,
13 | "materials" : 0
14 | },
15 |
16 | "scale" : 1.000000,
17 |
18 | "materials": [],
19 |
20 | "vertices": [-0.119373,-0.026000,0.625100,-0.119373,-0.026000,0.386354,0.119373,-0.026000,0.386354,0.119373,-0.026000,0.625100],
21 |
22 | "morphTargets": [],
23 |
24 | "morphColors": [],
25 |
26 | "normals": [0,-1,0],
27 |
28 | "colors": [],
29 |
30 | "uvs": [[0,0,1,0,1,1,0,1]],
31 |
32 | "faces": [42,1,2,3,0,0,1,2,0,0,0,42,0,1,3,0,3,0,2,0,0,0]
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/doc/images/oneqt-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/doc/images/oneqt-example.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleIconFile
6 |
7 | CFBundlePackageType
8 | APPL
9 | CFBundleGetInfoString
10 | Created by Qt/QMake
11 | CFBundleSignature
12 | ????
13 | CFBundleExecutable
14 | oneqt
15 | CFBundleIdentifier
16 | com.theqtcompany.${PRODUCT_NAME:rfc1034identifier}
17 | CFBundleDisplayName
18 | One Qt
19 | CFBundleName
20 | ${PRODUCT_NAME}
21 | CFBundleShortVersionString
22 | 1.0
23 | CFBundleVersion
24 | 1.0
25 | LSRequiresIPhoneOS
26 |
27 | UILaunchStoryboardName
28 | LaunchScreen
29 | UISupportedInterfaceOrientations
30 |
31 | UIInterfaceOrientationPortrait
32 | UIInterfaceOrientationPortraitUpsideDown
33 | UIInterfaceOrientationLandscapeLeft
34 | UIInterfaceOrientationLandscapeRight
35 |
36 |
37 | CFBundleIcons
38 |
39 | CFBundlePrimaryIcon
40 |
41 | CFBundleIconFiles
42 |
43 | OneQtIcon29x29.png
44 | OneQtIcon29x29@2x.png
45 | OneQtIcon40x40@2x.png
46 | OneQtIcon57x57.png
47 | OneQtIcon57x57@2x.png
48 | OneQtIcon60x60@2x.png
49 |
50 |
51 |
52 |
53 | CFBundleIcons~ipad
54 |
55 | CFBundlePrimaryIcon
56 |
57 | CFBundleIconFiles
58 |
59 | OneQtIcon29x29.png
60 | OneQtIcon29x29@2x.png
61 | OneQtIcon40x40@2x.png
62 | OneQtIcon57x57.png
63 | OneQtIcon57x57@2x.png
64 | OneQtIcon60x60@2x.png
65 | OneQtIcon29x29~ipad.png
66 | OneQtIcon29x29@2x~ipad.png
67 | OneQtIcon40x40~ipad.png
68 | OneQtIcon40x40@2x~ipad.png
69 | OneQtIcon50x50~ipad.png
70 | OneQtIcon50x50@2x~ipad.png
71 | OneQtIcon72x72~ipad.png
72 | OneQtIcon72x72@2x~ipad.png
73 | OneQtIcon76x76~ipad.png
74 | OneQtIcon76x76@2x~ipad.png
75 |
76 |
77 |
78 |
79 |
80 |
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon29x29~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon40x40~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon50x50@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon50x50@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon50x50~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon50x50~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon57x57.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon57x57.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon57x57@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon57x57@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon60x60@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon72x72@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon72x72@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon72x72~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon72x72~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon76x76@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon76x76@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/ios/OneQtIcon76x76~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/ios/OneQtIcon76x76~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 | #include
54 | #include
55 |
56 | int main(int argc, char *argv[])
57 | {
58 | QGuiApplication app(argc, argv);
59 |
60 | QQuickView viewer;
61 |
62 | // The following are needed to make examples run without having to install the module
63 | // in desktop environments.
64 | #ifdef Q_OS_WIN
65 | QString extraImportPath(QStringLiteral("%1/../../../../%2"));
66 | #else
67 | QString extraImportPath(QStringLiteral("%1/../../../%2"));
68 | #endif
69 | viewer.engine()->addImportPath(extraImportPath.arg(QGuiApplication::applicationDirPath(),
70 | QString::fromLatin1("qml")));
71 |
72 | viewer.setSource(QUrl("qrc:/oneqt.qml"));
73 |
74 | viewer.setTitle(QStringLiteral("One Qt"));
75 | viewer.setResizeMode(QQuickView::SizeRootObjectToView);
76 | viewer.setColor(QColor("#FCFCFC"));
77 | viewer.show();
78 |
79 | return app.exec();
80 | }
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/oneqt.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/threejs/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | OTHER_FILES += doc/src/* \
11 | doc/images/*
12 |
13 | RESOURCES += oneqt.qrc
14 |
15 | DISTFILES += \
16 | ImageCube.qml
17 |
18 | ios {
19 | ios_icon.files = $$files($$PWD/ios/OneQtIcon*.png)
20 | QMAKE_BUNDLE_DATA += ios_icon
21 | QMAKE_INFO_PLIST = ios/Info.plist
22 | }
23 |
24 | EXAMPLE_FILES += \
25 | ios
26 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/oneqt.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../../3rdparty/three.js
4 | oneqt.qml
5 | imagecube.js
6 | Navibutton.qml
7 | InfoSheet.qml
8 | textures/qtlogo.png
9 | textures/qtlogosmall.png
10 | textures/dataviz.jpg
11 | textures/devices.png
12 | textures/embedded.png
13 | textures/iot.png
14 | textures/multiscreen.png
15 | textures/puzzle-pieces.png
16 | ImageCube.qml
17 | SwipeArea.qml
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/dataviz.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/dataviz.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/devices.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/devices.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/embedded.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/embedded.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/iot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/iot.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/multiscreen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/multiscreen.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/puzzle-pieces.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/puzzle-pieces.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/qtlogo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/qtlogo.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/oneqt/textures/qtlogosmall.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/oneqt/textures/qtlogosmall.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/PlanetButton.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | import QtQuick 2.0
52 |
53 | Rectangle {
54 |
55 | id: planetButton
56 | property alias text: planetText.text
57 | property alias source: planetImage.source
58 | property alias focusPlanet: planetImage.focusPlanet
59 | property Item planetSelector: parent.parent
60 | property int buttonSize: 70
61 | property int fontSize: 16
62 |
63 | width: buttonSize; height: buttonSize
64 | color: "transparent"
65 |
66 | Image {
67 | id: planetImage
68 | anchors.fill: parent
69 | property int focusPlanet
70 |
71 | MouseArea {
72 | anchors.fill: parent
73 | hoverEnabled: true
74 | onClicked: { planetSelector.focusedPlanet = focusPlanet; }
75 | }
76 | }
77 |
78 | Text {
79 | id: planetText
80 | anchors.centerIn: parent
81 | font.family: "Helvetica"
82 | font.pixelSize: fontSize
83 | font.weight: Font.Light
84 | color: "white"
85 | }
86 |
87 | }
88 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/StyledSlider.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | import QtQuick 2.0
52 | import QtQuick.Controls 1.2
53 | import QtQuick.Controls.Styles 1.3
54 |
55 | Slider {
56 | id: styledSlider
57 |
58 | style: SliderStyle {
59 | groove: Rectangle {
60 | implicitWidth: 200
61 | implicitHeight: 5
62 | color: "#5d5b59"
63 | Rectangle {
64 | anchors.verticalCenter: parent.verticalCenter
65 | width: styleData.handlePosition
66 | height: 5
67 | gradient: Gradient {
68 | GradientStop { position: 0.0; color: "#80c342" }
69 | GradientStop { position: 1.0; color: "#328930" }
70 | }
71 | }
72 | }
73 | handle: Rectangle {
74 | Rectangle {
75 | anchors.centerIn: parent
76 | color: "#aeadac"
77 | border.color: "#1e1b18"
78 | border.width: 1
79 | implicitWidth: 8
80 | implicitHeight: 20
81 | }
82 | anchors.centerIn: parent
83 | color: "transparent"
84 | border.width: 0
85 | implicitWidth: 80
86 | implicitHeight: 80
87 | }
88 | }
89 | }
90 |
91 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/doc/images/planets-example.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/doc/images/planets-example.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/earth.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/earth.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/earthbump1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/earthbump1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/earthcloudmapcolortrans.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/earthcloudmapcolortrans.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/earthmap1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/earthmap1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/earthspec1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/earthspec1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/galaxy_starfield.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/galaxy_starfield.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/jupiter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/jupiter.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/jupitermap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/jupitermap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/mars.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/mars.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/marsbump1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/marsbump1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/marsmap1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/marsmap1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/mercury.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/mercury.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/mercurybump.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/mercurybump.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/mercurymap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/mercurymap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/moonbump1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/moonbump1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/moonmap1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/moonmap1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/neptune.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/neptune.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/neptunemap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/neptunemap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/plutobump1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/plutobump1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/plutomap1k.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/plutomap1k.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/saturn.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/saturn.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/saturnmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/saturnmap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/saturnringcolortrans.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/saturnringcolortrans.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/sun.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/sun.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/sunmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/sunmap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/uranus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/uranus.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/uranusmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/uranusmap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/uranusringcolortrans.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/uranusringcolortrans.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/venus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/venus.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/venusbump.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/venusbump.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/images/venusmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/images/venusmap.jpg
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon29x29.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon29x29.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon29x29@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon29x29@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon29x29@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon29x29~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon29x29~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon40x40@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon40x40@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon40x40@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon40x40~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon40x40~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon50x50@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon50x50@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon50x50~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon50x50~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon57x57.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon57x57.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon57x57@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon57x57@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon60x60@2x.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon72x72@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon72x72@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon72x72~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon72x72~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon76x76@2x~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon76x76@2x~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/AppIcon76x76~ipad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/examples/canvas3d/threejs/planets/ios/AppIcon76x76~ipad.png
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/ios/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleIconFile
6 |
7 | CFBundlePackageType
8 | APPL
9 | CFBundleGetInfoString
10 | Created by Qt/QMake
11 | CFBundleSignature
12 | ????
13 | CFBundleExecutable
14 | planets
15 | CFBundleIdentifier
16 | com.theqtcompany.${PRODUCT_NAME:rfc1034identifier}
17 | CFBundleDisplayName
18 | Planets
19 | CFBundleName
20 | ${PRODUCT_NAME}
21 | CFBundleShortVersionString
22 | 1.0
23 | CFBundleVersion
24 | 1.0
25 | LSRequiresIPhoneOS
26 |
27 | UILaunchStoryboardName
28 | LaunchScreen
29 | UISupportedInterfaceOrientations
30 |
31 | UIInterfaceOrientationPortrait
32 | UIInterfaceOrientationPortraitUpsideDown
33 | UIInterfaceOrientationLandscapeLeft
34 | UIInterfaceOrientationLandscapeRight
35 |
36 |
37 | CFBundleIcons
38 |
39 | CFBundlePrimaryIcon
40 |
41 | CFBundleIconFiles
42 |
43 | AppIcon29x29.png
44 | AppIcon29x29@2x.png
45 | AppIcon40x40@2x.png
46 | AppIcon57x57.png
47 | AppIcon57x57@2x.png
48 | AppIcon60x60@2x.png
49 |
50 |
51 |
52 |
53 | CFBundleIcons~ipad
54 |
55 | CFBundlePrimaryIcon
56 |
57 | CFBundleIconFiles
58 |
59 | AppIcon29x29.png
60 | AppIcon29x29@2x.png
61 | AppIcon40x40@2x.png
62 | AppIcon57x57.png
63 | AppIcon57x57@2x.png
64 | AppIcon60x60@2x.png
65 | AppIcon29x29~ipad.png
66 | AppIcon29x29@2x~ipad.png
67 | AppIcon40x40~ipad.png
68 | AppIcon40x40@2x~ipad.png
69 | AppIcon50x50~ipad.png
70 | AppIcon50x50@2x~ipad.png
71 | AppIcon72x72~ipad.png
72 | AppIcon72x72@2x~ipad.png
73 | AppIcon76x76~ipad.png
74 | AppIcon76x76@2x~ipad.png
75 |
76 |
77 |
78 |
79 |
80 |
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:BSD$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** BSD License Usage
18 | ** Alternatively, you may use this file under the terms of the BSD license
19 | ** as follows:
20 | **
21 | ** "Redistribution and use in source and binary forms, with or without
22 | ** modification, are permitted provided that the following conditions are
23 | ** met:
24 | ** * Redistributions of source code must retain the above copyright
25 | ** notice, this list of conditions and the following disclaimer.
26 | ** * Redistributions in binary form must reproduce the above copyright
27 | ** notice, this list of conditions and the following disclaimer in
28 | ** the documentation and/or other materials provided with the
29 | ** distribution.
30 | ** * Neither the name of The Qt Company Ltd nor the names of its
31 | ** contributors may be used to endorse or promote products derived
32 | ** from this software without specific prior written permission.
33 | **
34 | **
35 | ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
36 | ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
37 | ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
38 | ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
39 | ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
40 | ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
41 | ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
42 | ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
43 | ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
44 | ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
45 | ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
46 | **
47 | ** $QT_END_LICENSE$
48 | **
49 | ****************************************************************************/
50 |
51 | #include
52 | #include
53 | #include
54 | #include
55 |
56 | int main(int argc, char *argv[])
57 | {
58 | QGuiApplication app(argc, argv);
59 |
60 | QQuickView viewer;
61 |
62 | // The following are needed to make examples run without having to install the module
63 | // in desktop environments.
64 | #ifdef Q_OS_WIN
65 | QString extraImportPath(QStringLiteral("%1/../../../../%2"));
66 | #else
67 | QString extraImportPath(QStringLiteral("%1/../../../%2"));
68 | #endif
69 | viewer.engine()->addImportPath(extraImportPath.arg(QGuiApplication::applicationDirPath(),
70 | QString::fromLatin1("qml")));
71 |
72 | viewer.setSource(QUrl("qrc:/planets.qml"));
73 |
74 | viewer.setTitle(QStringLiteral("Qt Canvas 3D Examples - Planets"));
75 | viewer.setResizeMode(QQuickView::SizeRootObjectToView);
76 | viewer.setColor(Qt::black);
77 | viewer.show();
78 |
79 | return app.exec();
80 | }
81 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/planets.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | target.path = $$[QT_INSTALL_EXAMPLES]/canvas3d/threejs/$$TARGET
6 | INSTALLS += target
7 |
8 | SOURCES += main.cpp
9 |
10 | OTHER_FILES += *.qml \
11 | planets.js \
12 | doc/src/* \
13 | doc/images/*
14 |
15 | RESOURCES += planets.qrc
16 |
17 | ios {
18 | ios_icon.files = $$files($$PWD/ios/AppIcon*.png)
19 | QMAKE_BUNDLE_DATA += ios_icon
20 | QMAKE_INFO_PLIST = ios/Info.plist
21 | }
22 |
23 | EXAMPLE_FILES += \
24 | ios
25 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/planets/planets.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | planets.qml
4 | PlanetButton.qml
5 | InfoSheet.qml
6 | StyledSlider.qml
7 | FpsDisplay.qml
8 | ../../3rdparty/three.js
9 | ../controls/ControlEventSource.qml
10 | ../../3rdparty/threex.planets.js
11 | planets.js
12 |
13 |
14 | images/sunmap.jpg
15 | images/mercurymap.jpg
16 | images/mercurybump.jpg
17 | images/venusmap.jpg
18 | images/venusbump.jpg
19 | images/earthmap1k.jpg
20 | images/earthbump1k.jpg
21 | images/earthspec1k.jpg
22 | images/moonmap1k.jpg
23 | images/moonbump1k.jpg
24 | images/marsmap1k.jpg
25 | images/marsbump1k.jpg
26 | images/jupitermap.jpg
27 | images/saturnmap.jpg
28 | images/uranusmap.jpg
29 | images/neptunemap.jpg
30 | images/earth.png
31 | images/mercury.png
32 | images/jupiter.png
33 | images/mars.png
34 | images/neptune.png
35 | images/saturn.png
36 | images/sun.png
37 | images/uranus.png
38 | images/venus.png
39 | images/earthcloudmapcolortrans.png
40 | images/saturnringcolortrans.png
41 | images/uranusringcolortrans.png
42 | images/galaxy_starfield.png
43 |
44 |
45 |
--------------------------------------------------------------------------------
/examples/canvas3d/threejs/threejs.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | SUBDIRS += oneqt \
3 | planets \
4 | cellphone
5 |
6 | EXAMPLE_FILES = controls
7 |
--------------------------------------------------------------------------------
/examples/examples.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | SUBDIRS += canvas3d
3 |
4 |
--------------------------------------------------------------------------------
/qtcanvas3d.pro:
--------------------------------------------------------------------------------
1 | requires(contains(QT_CONFIG, opengl))
2 | requires(qtHaveModule(network))
3 |
4 | load(qt_parts)
5 |
6 | # We need opengl, minimum es2
7 | contains(QT_CONFIG, opengles1) {
8 | error("QtCanvas3D does not support OpenGL ES 1!")
9 | }
10 |
--------------------------------------------------------------------------------
/src/imports/imports.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 |
3 | qtHaveModule(quick):contains(QT_CONFIG, opengl) {
4 | SUBDIRS += qtcanvas3d
5 | }
6 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/activeinfo3d.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "activeinfo3d_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | /*!
46 | * \qmltype Canvas3DActiveInfo
47 | * \since QtCanvas3D 1.0
48 | * \inqmlmodule QtCanvas3D
49 | * \brief Active attribute or uniform information.
50 | * \deprecated
51 | *
52 | * \b{Deprecated in Qt 5.12.} An uncreatable QML type that contains the
53 | * information returned from the Context3D::getActiveAttrib() and
54 | * Context3D::getActiveUniform() calls.
55 | *
56 | * \sa Context3D, Canvas3D
57 | */
58 |
59 | CanvasActiveInfo::CanvasActiveInfo(int size, CanvasContext::glEnums type,
60 | QString name, QObject *parent) :
61 | QObject(parent),
62 | m_size(size),
63 | m_type(type),
64 | m_name(name)
65 | {
66 | }
67 |
68 | /*!
69 | * \qmlproperty string Canvas3DActiveInfo::name
70 | * \b{Deprecated in Qt 5.12.} Name of the attribute or the uniform.
71 | */
72 | const QString CanvasActiveInfo::name() const
73 | {
74 | return m_name;
75 | }
76 |
77 | /*!
78 | * \qmlproperty string Canvas3DActiveInfo::size
79 | * \b{Deprecated in Qt 5.12.} Size of the attribute or the uniform, in units of
80 | * its type.
81 | *
82 | * \sa type
83 | */
84 | int CanvasActiveInfo::size() const
85 | {
86 | return m_size;
87 | }
88 |
89 | /*!
90 | * \qmlproperty string Canvas3DActiveInfo::type
91 | * \b{Deprecated in Qt 5.12.} Type of the attribute or the uniform.
92 | */
93 | CanvasContext::glEnums CanvasActiveInfo::type() const
94 | {
95 | return m_type;
96 | }
97 |
98 | QT_CANVAS3D_END_NAMESPACE
99 | QT_END_NAMESPACE
100 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/activeinfo3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef CANVASACTIVEINFO_P_H
51 | #define CANVASACTIVEINFO_P_H
52 |
53 | #include "context3d_p.h"
54 | #include
55 |
56 | QT_BEGIN_NAMESPACE
57 | QT_CANVAS3D_BEGIN_NAMESPACE
58 |
59 | class CanvasActiveInfo : public QObject
60 | {
61 | Q_OBJECT
62 |
63 | Q_PROPERTY(int size READ size NOTIFY sizeChanged)
64 | Q_PROPERTY(QtCanvas3D::CanvasContext::glEnums type READ type NOTIFY typeChanged)
65 | Q_PROPERTY(QString name READ name NOTIFY nameChanged)
66 |
67 | public:
68 | explicit CanvasActiveInfo(int size, CanvasContext::glEnums type,
69 | QString name, QObject *parent = 0);
70 |
71 | int size() const;
72 | CanvasContext::glEnums type() const;
73 | const QString name() const;
74 |
75 | signals:
76 | void sizeChanged(int size);
77 | void typeChanged(CanvasContext::glEnums type);
78 | void nameChanged(const QString name);
79 |
80 | private:
81 | int m_size;
82 | CanvasContext::glEnums m_type;
83 | QString m_name;
84 | };
85 |
86 | QT_CANVAS3D_END_NAMESPACE
87 | QT_END_NAMESPACE
88 |
89 | #endif // CANVASACTIVEINFO_P_H
90 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/arrayutils.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "arrayutils_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | void ArrayUtils::fillFloatArrayFromVariantList(const QVariantList &list, float *outArray)
46 | {
47 | int idx = 0;
48 | for (QVariantList::const_iterator it = list.begin(); it != list.end(); ++it) {
49 | QVariant element = *it;
50 | if (element.canConvert()) {
51 | outArray[idx] = element.toFloat();
52 | }
53 | else {
54 | // Conversion failed, use 0.0 as default value
55 | outArray[idx] = 0.f;
56 | }
57 | idx++;
58 | }
59 | }
60 |
61 | void ArrayUtils::fillIntArrayFromVariantList(const QVariantList &list, int *outArray)
62 | {
63 | int idx = 0;
64 | for (QVariantList::const_iterator it = list.begin(); it != list.end(); ++it) {
65 | QVariant element = *it;
66 | if (element.canConvert()) {
67 | outArray[idx] = element.toInt();
68 | }
69 | else {
70 | // Conversion failed, use 0.0 as default value
71 | outArray[idx] = 0;
72 | }
73 | idx++;
74 | }
75 | }
76 |
77 | QT_CANVAS3D_END_NAMESPACE
78 | QT_END_NAMESPACE
79 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/arrayutils_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef ARRAYUTILS_P_H
51 | #define ARRAYUTILS_P_H
52 |
53 | #include "canvas3dcommon_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class ArrayUtils
61 | {
62 | public:
63 | static void fillFloatArrayFromVariantList(const QVariantList &list, float *outArray);
64 | static void fillIntArrayFromVariantList(const QVariantList &list, int *outArray);
65 | };
66 |
67 | QT_CANVAS3D_END_NAMESPACE
68 | QT_END_NAMESPACE
69 |
70 | #endif // ARRAYUTILS_P_H
71 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/buffer3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef BUFFER3D_P_H
51 | #define BUFFER3D_P_H
52 |
53 | #include "context3d_p.h"
54 | #include "abstractobject3d_p.h"
55 |
56 | QT_BEGIN_NAMESPACE
57 | QT_CANVAS3D_BEGIN_NAMESPACE
58 |
59 | class CanvasBuffer : public CanvasAbstractObject
60 | {
61 | Q_OBJECT
62 |
63 | public:
64 | enum bindTarget {
65 | UNINITIALIZED = 0,
66 | ARRAY_BUFFER,
67 | ELEMENT_ARRAY_BUFFER
68 | };
69 |
70 | explicit CanvasBuffer();
71 | explicit CanvasBuffer(CanvasGlCommandQueue *queue, QObject *parent);
72 | CanvasBuffer(const CanvasBuffer& other);
73 | virtual ~CanvasBuffer();
74 |
75 | void del();
76 | bool isAlive();
77 | GLint id();
78 | bindTarget target();
79 | void setTarget(bindTarget bindPoint);
80 |
81 | friend QDebug operator<< (QDebug d, const CanvasBuffer *buffer);
82 |
83 | private:
84 | GLint m_bufferId;
85 | bindTarget m_bindTarget;
86 | };
87 |
88 | QT_CANVAS3D_END_NAMESPACE
89 | QT_END_NAMESPACE
90 |
91 | #endif // BUFFER3D_P_H
92 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/canvas3dcommon_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2018 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 | //
40 | // W A R N I N G
41 | // -------------
42 | //
43 | // This file is not part of the QtCanvas3D API. It exists purely as an
44 | // implementation detail. This header file may change from version to
45 | // version without notice, or even be removed.
46 | //
47 | // We mean it.
48 |
49 | #include
50 |
51 | #ifndef CANVAS3DCOMMON_P_H
52 | #define CANVAS3DCOMMON_P_H
53 |
54 | #define QT_CANVAS3D_EXPORT Q_DECL_EXPORT
55 |
56 | #define VERBOSE_ALL_TYPED_ARRAY_CALLS false
57 |
58 | #ifdef Q_CLANG_QDOC
59 | #define QT_CANVAS3D_BEGIN_NAMESPACE
60 | #define QT_CANVAS3D_END_NAMESPACE
61 | #else
62 | #define QT_CANVAS3D_BEGIN_NAMESPACE namespace QtCanvas3D {
63 | #define QT_CANVAS3D_END_NAMESPACE }
64 | #endif // Q_CLANG_QDOC
65 |
66 | #endif // CANVAS3DCOMMON_P_H
67 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/canvasrendernode_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef CANVASRENDERNODE_P_H
51 | #define CANVASRENDERNODE_P_H
52 |
53 | #include "canvas3dcommon_p.h"
54 | #include
55 | #include
56 | #include
57 |
58 | QT_BEGIN_NAMESPACE
59 | QT_CANVAS3D_BEGIN_NAMESPACE
60 |
61 | class Canvas;
62 |
63 | class CanvasRenderNode : public QObject, public QSGSimpleTextureNode
64 | {
65 | Q_OBJECT
66 |
67 | public:
68 | CanvasRenderNode(QQuickWindow *window);
69 | ~CanvasRenderNode();
70 |
71 | void setAlpha(bool alpha);
72 |
73 | public slots:
74 | void newTexture(int id, const QSize &size);
75 |
76 | private:
77 | GLuint m_defaultTexture;
78 | QSGTexture *m_texture;
79 | QQuickWindow *m_window;
80 | QQuickWindow::CreateTextureOptions m_textureOptions;
81 | };
82 |
83 | QT_CANVAS3D_END_NAMESPACE
84 | QT_END_NAMESPACE
85 |
86 | #endif // CANVASRENDERNODE_P_H
87 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/canvastextureprovider_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef CANVASTEXTUREPROVIDER_P_H
51 | #define CANVASTEXTUREPROVIDER_P_H
52 |
53 | #include "canvas3dcommon_p.h"
54 |
55 | #include
56 | #include
57 | #include
58 |
59 | QT_BEGIN_NAMESPACE
60 | QT_CANVAS3D_BEGIN_NAMESPACE
61 |
62 | class CanvasContext;
63 |
64 | class CanvasTextureProvider : public QObject
65 | {
66 | Q_OBJECT
67 | public:
68 | CanvasTextureProvider(CanvasContext *canvasContext, QObject *parent = 0);
69 | ~CanvasTextureProvider();
70 |
71 | Q_INVOKABLE QJSValue createTextureFromSource(QQuickItem *source);
72 |
73 | signals:
74 | void textureReady(QQuickItem *source);
75 |
76 | private:
77 | CanvasContext *m_canvasContext;
78 | QJSValue m_textureObject;
79 | };
80 |
81 | QT_CANVAS3D_END_NAMESPACE
82 | QT_END_NAMESPACE
83 |
84 | #endif // CANVASTEXTUREPROVIDER_P_H
85 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/compressedtexturepvrtc.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "compressedtexturepvrtc_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | CompressedTexturePVRTC::CompressedTexturePVRTC(QObject *parent) : QObject(parent)
46 | {
47 |
48 | }
49 |
50 | CompressedTexturePVRTC::~CompressedTexturePVRTC()
51 | {
52 |
53 | }
54 |
55 | QT_CANVAS3D_END_NAMESPACE
56 | QT_END_NAMESPACE
57 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/compressedtextures3tc.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "compressedtextures3tc_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | CompressedTextureS3TC::CompressedTextureS3TC(QObject *parent) : QObject(parent)
46 | {
47 | }
48 |
49 | CompressedTextureS3TC::~CompressedTextureS3TC()
50 | {
51 | }
52 |
53 | QT_CANVAS3D_END_NAMESPACE
54 | QT_END_NAMESPACE
55 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/doc/QtCanvas3D:
--------------------------------------------------------------------------------
1 | #include "../canvas3dcommon_p.h"
2 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/doc/qtcanvas3d.qdocconf:
--------------------------------------------------------------------------------
1 | include($QT_INSTALL_DOCS/global/qt-module-defaults.qdocconf)
2 |
3 | project = QtCanvas3D
4 | description = Qt Canvas 3D Reference Documentation
5 | version = $QT_VERSION
6 |
7 | # Qt Canvas 3D doesn't expose a C++ API - pass a dummy header for Clang parser
8 | moduleheader = QtCanvas3D
9 | includepaths = .
10 |
11 | exampledirs = ../../../../examples/canvas3d \
12 | snippets
13 |
14 | imagedirs += images
15 | headerdirs += ..
16 | sourcedirs += ..
17 |
18 | examplesinstallpath = canvas3d
19 |
20 | depends = qtcore qtgui qtqml qtquick qtquickcontrols qtquicklayouts qtdoc qtmultimedia
21 |
22 | qhp.projects = QtCanvas3D
23 |
24 | qhp.QtCanvas3D.file = qtcanvas3d.qhp
25 | qhp.QtCanvas3D.namespace = org.qt-project.qtcanvas3d.$QT_VERSION_TAG
26 | qhp.QtCanvas3D.virtualFolder = qtcanvas3d
27 | qhp.QtCanvas3D.indexTitle = Qt Canvas 3D
28 | qhp.QtCanvas3D.indexRoot =
29 |
30 |
31 | qhp.QtCanvas3D.filterAttributes = qtcanvas3d $QT_VERSION qtrefdoc
32 | qhp.QtCanvas3D.customFilters.Qt.name = QtCanvas3D $QT_VERSION
33 | qhp.QtCanvas3D.customFilters.Qt.filterAttributes = qtcanvas3d $QT_VERSION
34 | qhp.QtCanvas3D.subprojects = gettingstarted examples types
35 | qhp.QtCanvas3D.subprojects.gettingstarted.title = Getting Started
36 | qhp.QtCanvas3D.subprojects.gettingstarted.indexTitle = Qt Canvas 3D Getting Started
37 | qhp.QtCanvas3D.subprojects.gettingstarted.selectors = fake:page
38 | qhp.QtCanvas3D.subprojects.gettingstarted.sortPages = true
39 | qhp.QtCanvas3D.subprojects.examples.title = Examples
40 | qhp.QtCanvas3D.subprojects.examples.indexTitle = Qt Canvas 3D Examples
41 | qhp.QtCanvas3D.subprojects.examples.selectors = fake:example
42 | qhp.QtCanvas3D.subprojects.examples.sortPages = true
43 | qhp.QtCanvas3D.subprojects.types.title = QML Types
44 | qhp.QtCanvas3D.subprojects.types.indexTitle = Qt Canvas 3D QML Types
45 | qhp.QtCanvas3D.subprojects.types.selectors = qmlclass
46 | qhp.QtCanvas3D.subprojects.types.sortPages = true
47 |
48 | navigation.landingpage = Qt Canvas 3D
49 | navigation.landingtitle = Qt Canvas 3D (deprecated)
50 | navigation.qmltypespage = Qt Canvas 3D QML Types
51 | navigation.qmltypestitle = Qt Canvas 3D QML Types (deprecated)
52 | navigation.examplespage = Qt Canvas 3D Examples
53 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/doc/snippets/doc_src_qtcanvas3d.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //! [0]
41 | import QtCanvas3D 1.1
42 | //! [0]
43 |
44 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/doc/snippets/doc_src_qtcanvas3d.pro:
--------------------------------------------------------------------------------
1 | #! [0]
2 | QT += qtcanvas3d
3 | #! [0]
4 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/doc/src/qtcanvas3d-index.qdoc:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the documentation of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:FDL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Free Documentation License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Free
19 | ** Documentation License version 1.3 as published by the Free Software
20 | ** Foundation and appearing in the file included in the packaging of
21 | ** this file. Please review the following information to ensure
22 | ** the GNU Free Documentation License version 1.3 requirements
23 | ** will be met: https://www.gnu.org/licenses/fdl-1.3.html.
24 | ** $QT_END_LICENSE$
25 | **
26 | ****************************************************************************/
27 |
28 | /*!
29 | \title Qt Canvas 3D
30 | \page qtcanvas3d-index.html
31 | \brief Provides functionality for 3D drawing inside Qt Quick 2.
32 |
33 | \b{Canvas3D module was deprecated in Qt 5.12.} Depracated modules are no
34 | longer maintained. They are provided to keep old source code working, but
35 | they can be removed in a future release. We strongly advise against using
36 | deprecated modules in new code or project.
37 |
38 | Qt Canvas 3D module provides a way to make WebGL-like 3D drawing calls
39 | from Qt Quick JavaScript.
40 |
41 | \section1 Features
42 |
43 | \list
44 | \li Uses OpenGL or OpenGL ES 2 for rendering.
45 | \li Qt Quick 2 support.
46 | \li Use Qt Quick items as texture sources.
47 | \li Render content via offscreen framebuffer, or directly into Qt Quick scene
48 | background or foreground.
49 | \endlist
50 |
51 | \section1 Getting Started
52 |
53 | To import Qt Canvas 3D QML types, add the following import statement to
54 | your \c .qml file:
55 |
56 | \snippet doc_src_qtcanvas3d.cpp 0
57 |
58 | See the \l{Qt Canvas 3D Getting Started}{Getting Started} page for further
59 | information on how to use Qt Canvas 3D in your application.
60 |
61 | \section1 References
62 |
63 | \list
64 | \li \l{Qt Canvas 3D Getting Started}
65 | \li \l{Qt Canvas 3D QML Types}
66 | \li \l{Qt Canvas 3D Examples}
67 | \li \l{Qt Canvas 3D Logging}
68 | \li \l{Qt Canvas 3D Known WebGL Conformance Issues}
69 | \endlist
70 | */
71 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/enumtostringmap_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef ENUMTOSTRINGMAP_P_H
51 | #define ENUMTOSTRINGMAP_P_H
52 |
53 | #include "context3d_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class EnumToStringMap
61 | {
62 | public:
63 | static EnumToStringMap *newInstance();
64 | static void deleteInstance();
65 | QString lookUp(const CanvasContext::glEnums value) const;
66 | QString lookUp(const GLuint value) const;
67 |
68 | private:
69 | EnumToStringMap();
70 | QMap m_map;
71 | QString m_unknown;
72 | };
73 |
74 | QT_CANVAS3D_END_NAMESPACE
75 | QT_END_NAMESPACE
76 |
77 | #endif // ENUMTOSTRINGMAP_P_H
78 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/framebuffer3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef FRAMEBUFFER3D_P_H
51 | #define FRAMEBUFFER3D_P_H
52 |
53 | #include "abstractobject3d_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class CanvasTexture;
61 |
62 | class CanvasFrameBuffer : public CanvasAbstractObject
63 | {
64 | Q_OBJECT
65 |
66 | public:
67 | explicit CanvasFrameBuffer(CanvasGlCommandQueue *queue, QObject *parent);
68 | virtual ~CanvasFrameBuffer();
69 |
70 | bool isAlive();
71 | void del();
72 | GLint id();
73 | void setTexture(CanvasTexture *texture);
74 | CanvasTexture *texture();
75 |
76 | friend QDebug operator<< (QDebug d, const CanvasFrameBuffer *fb);
77 |
78 | private:
79 | GLint m_framebufferId;
80 | CanvasTexture *m_texture; // Not owned
81 | };
82 |
83 | QT_CANVAS3D_END_NAMESPACE
84 | QT_END_NAMESPACE
85 |
86 | #endif // FRAMEBUFFER3D_P_H
87 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/openglversionchecker_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: http://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef OPENGLVERSIONCHECKER_P_H
51 | #define OPENGLVERSIONCHECKER_P_H
52 |
53 | #include "canvas3dcommon_p.h"
54 | #include
55 |
56 | QT_BEGIN_NAMESPACE
57 | QT_CANVAS3D_BEGIN_NAMESPACE
58 |
59 | class OpenGLVersionChecker
60 | {
61 | Q_DISABLE_COPY(OpenGLVersionChecker)
62 |
63 | public:
64 | OpenGLVersionChecker();
65 | ~OpenGLVersionChecker() {};
66 |
67 | bool isSoftwareRenderer() const { return m_softwareRenderer; }
68 |
69 | private:
70 | bool m_softwareRenderer;
71 | };
72 |
73 | QT_CANVAS3D_END_NAMESPACE
74 | QT_END_NAMESPACE
75 |
76 | #endif // OPENGLVERSIONCHECKER_P_H
77 |
78 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/program3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef PROGRAM3D_P_H
51 | #define PROGRAM3D_P_H
52 |
53 | #include "context3d_p.h"
54 | #include "abstractobject3d_p.h"
55 | #include "shader3d_p.h"
56 |
57 | #include
58 | #include
59 |
60 | QT_BEGIN_NAMESPACE
61 | QT_CANVAS3D_BEGIN_NAMESPACE
62 |
63 | class CanvasProgram : public CanvasAbstractObject
64 | {
65 | Q_OBJECT
66 |
67 | public:
68 | explicit CanvasProgram(CanvasGlCommandQueue *queue, QObject *parent);
69 | virtual ~CanvasProgram();
70 |
71 | void del();
72 | bool isAlive();
73 | void validateProgram();
74 | GLint id();
75 | void link();
76 | bool isLinked();
77 | void useProgram();
78 | void bindAttributeLocation(int index, const QString &name);
79 |
80 | void attach(CanvasShader *shader);
81 | void detach(CanvasShader *shader);
82 | const QList &attachedShaders() const;
83 |
84 | friend QDebug operator<< (QDebug d, const CanvasProgram *program);
85 |
86 | private:
87 | GLint m_programId;
88 | QList m_attachedShaders;
89 | bool m_linked;
90 | };
91 |
92 | QT_CANVAS3D_END_NAMESPACE
93 | QT_END_NAMESPACE
94 |
95 | #endif // PROGRAM3D_P_H
96 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/qcanvas3d_plugin.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #ifndef QCANVAS3D_PLUGIN_H
41 | #define QCANVAS3D_PLUGIN_H
42 |
43 | #include "canvas3d_p.h"
44 | #include "texture3d_p.h"
45 | #include "shader3d_p.h"
46 | #include "context3d_p.h"
47 | #include "program3d_p.h"
48 | #include "buffer3d_p.h"
49 | #include "uniformlocation_p.h"
50 | #include "teximage3d_p.h"
51 | #include "contextattributes_p.h"
52 | #include "framebuffer3d_p.h"
53 | #include "renderbuffer3d_p.h"
54 | #include "shaderprecisionformat_p.h"
55 | #include "activeinfo3d_p.h"
56 | #include "canvasglstatedump_p.h"
57 | #include "canvastextureprovider_p.h"
58 |
59 | #include
60 |
61 | using namespace QtCanvas3D;
62 |
63 | Q_DECLARE_METATYPE(CanvasBuffer)
64 |
65 | QML_DECLARE_TYPE(Canvas)
66 | QML_DECLARE_TYPE(CanvasContext)
67 | QML_DECLARE_TYPE(CanvasTexture)
68 | QML_DECLARE_TYPE(CanvasShader)
69 | QML_DECLARE_TYPE(CanvasProgram)
70 | QML_DECLARE_TYPE(CanvasBuffer)
71 | QML_DECLARE_TYPE(CanvasUniformLocation)
72 | QML_DECLARE_TYPE(CanvasTextureImage)
73 | QML_DECLARE_TYPE(CanvasTextureImageFactory)
74 | QML_DECLARE_TYPE(CanvasContextAttributes)
75 | QML_DECLARE_TYPE(CanvasFrameBuffer)
76 | QML_DECLARE_TYPE(CanvasRenderBuffer)
77 | QML_DECLARE_TYPE(CanvasShaderPrecisionFormat)
78 | QML_DECLARE_TYPE(CanvasActiveInfo)
79 | QML_DECLARE_TYPE(CanvasGLStateDump)
80 | QML_DECLARE_TYPE(CanvasTextureProvider)
81 |
82 | QT_BEGIN_NAMESPACE
83 | QT_CANVAS3D_BEGIN_NAMESPACE
84 |
85 | class QtCanvas3DPlugin : public QQmlExtensionPlugin
86 | {
87 | Q_OBJECT
88 | Q_PLUGIN_METADATA(IID QQmlExtensionInterface_iid)
89 |
90 | public:
91 | QtCanvas3DPlugin(QObject *parent = 0);
92 | void registerTypes(const char *uri);
93 | };
94 |
95 | QT_CANVAS3D_END_NAMESPACE
96 | QT_END_NAMESPACE
97 |
98 | #endif // QCANVAS3D_PLUGIN_H
99 |
100 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/qmldir:
--------------------------------------------------------------------------------
1 | module QtCanvas3D
2 | plugin qtcanvas3d
3 | classname QtCanvas3DPlugin
4 | typeinfo plugins.qmltypes
5 |
6 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/qtcanvas3d.pro:
--------------------------------------------------------------------------------
1 | QT += openglextensions qml quick qml-private core-private
2 | DEFINES += QTCANVAS3D_LIBRARY
3 | TARGETPATH = QtCanvas3D
4 | IMPORT_VERSION = 1.1
5 |
6 | QMAKE_DOCS = $$PWD/doc/qtcanvas3d.qdocconf
7 |
8 | SOURCES += arrayutils.cpp \
9 | qcanvas3d_plugin.cpp \
10 | enumtostringmap.cpp \
11 | abstractobject3d.cpp \
12 | canvas3d.cpp \
13 | buffer3d.cpp \
14 | canvasrendernode.cpp \
15 | context3d.cpp \
16 | contextattributes.cpp \
17 | framebuffer3d.cpp \
18 | program3d.cpp \
19 | renderbuffer3d.cpp \
20 | shader3d.cpp \
21 | shaderprecisionformat.cpp \
22 | teximage3d.cpp \
23 | texture3d.cpp \
24 | uniformlocation.cpp \
25 | activeinfo3d.cpp \
26 | canvasglstatedump.cpp \
27 | compressedtextures3tc.cpp \
28 | compressedtexturepvrtc.cpp \
29 | glcommandqueue.cpp \
30 | renderjob.cpp \
31 | canvasrenderer.cpp \
32 | canvastextureprovider.cpp \
33 | glstatestore.cpp \
34 | openglversionchecker.cpp
35 |
36 | HEADERS += arrayutils_p.h \
37 | qcanvas3d_plugin.h \
38 | enumtostringmap_p.h \
39 | abstractobject3d_p.h \
40 | canvas3d_p.h \
41 | buffer3d_p.h \
42 | canvas3dcommon_p.h \
43 | canvasrendernode_p.h \
44 | context3d_p.h \
45 | contextattributes_p.h \
46 | framebuffer3d_p.h \
47 | program3d_p.h \
48 | renderbuffer3d_p.h \
49 | shader3d_p.h \
50 | shaderprecisionformat_p.h \
51 | teximage3d_p.h \
52 | texture3d_p.h \
53 | uniformlocation_p.h \
54 | activeinfo3d_p.h \
55 | canvasglstatedump_p.h \
56 | compressedtextures3tc_p.h \
57 | compressedtexturepvrtc_p.h \
58 | glcommandqueue_p.h \
59 | renderjob_p.h \
60 | canvasrenderer_p.h \
61 | canvastextureprovider_p.h \
62 | glstatestore_p.h \
63 | openglversionchecker_p.h
64 |
65 | OTHER_FILES = qmldir \
66 | doc/* \
67 | doc/src/* \
68 | doc/images/* \
69 | doc/snippets/*
70 |
71 | CONFIG += no_cxx_module
72 |
73 | load(qml_plugin)
74 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/renderbuffer3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef RENDERBUFFER3D_P_H
51 | #define RENDERBUFFER3D_P_H
52 |
53 | #include "abstractobject3d_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class CanvasRenderBuffer : public CanvasAbstractObject
61 | {
62 | Q_OBJECT
63 | public:
64 | explicit CanvasRenderBuffer(CanvasGlCommandQueue *queue, bool initSecondaryId,
65 | QObject *parent = 0);
66 | ~CanvasRenderBuffer();
67 | bool isAlive();
68 | void del();
69 | GLint id();
70 | GLint secondaryId();
71 |
72 | private:
73 | GLint m_renderbufferId;
74 | GLint m_secondaryId;
75 | };
76 |
77 | QT_CANVAS3D_END_NAMESPACE
78 | QT_END_NAMESPACE
79 |
80 | #endif // RENDERBUFFER3D_P_H
81 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/renderjob_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef RENDERJOB_P_H
51 | #define RENDERJOB_P_H
52 |
53 | #include "canvas3dcommon_p.h"
54 | #include "glcommandqueue_p.h"
55 |
56 | #include
57 | #include
58 | #include
59 | #include
60 |
61 | QT_BEGIN_NAMESPACE
62 | QT_CANVAS3D_BEGIN_NAMESPACE
63 |
64 | class CanvasRenderer;
65 |
66 | class CanvasRenderJob : public QRunnable
67 | {
68 | public:
69 | CanvasRenderJob(GlSyncCommand *command, QMutex *mutex,
70 | QWaitCondition *condition, QtCanvas3D::CanvasRenderer *renderer,
71 | bool *deleted);
72 | ~CanvasRenderJob();
73 |
74 | void run();
75 |
76 | private:
77 | void notifyGuiThread();
78 |
79 | // None of these objects are owned by the render job
80 | GlSyncCommand *m_command;
81 | QMutex *m_mutex;
82 | QWaitCondition *m_condition;
83 | CanvasRenderer *m_renderer;
84 | bool *m_deleted;
85 | QThread *m_creationThread;
86 | };
87 |
88 | QT_CANVAS3D_END_NAMESPACE
89 | QT_END_NAMESPACE
90 |
91 | #endif // RENDERJOBS_P_H
92 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/shader3d.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "shader3d_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | /*!
46 | * \qmltype Canvas3DShader
47 | * \since QtCanvas3D 1.0
48 | * \inqmlmodule QtCanvas3D
49 | * \inherits Canvas3DAbstractObject
50 | * \brief Contains a shader.
51 | * \deprecated
52 | *
53 | * \b{Deprecated in Qt 5.12.}
54 | * An uncreatable QML type that contains a shader. You can get it by calling
55 | * the \l{Context3D::createShader()}{Context3D.createShader()} method.
56 | */
57 |
58 | CanvasShader::CanvasShader(GLenum type, CanvasGlCommandQueue *queue, QObject *parent) :
59 | CanvasAbstractObject(queue, parent),
60 | m_shaderId(queue->createResourceId()),
61 | m_sourceCode("")
62 | {
63 | queueCommand(CanvasGlCommandQueue::glCreateShader, GLint(type), m_shaderId);
64 | }
65 |
66 | CanvasShader::~CanvasShader()
67 | {
68 | del();
69 | }
70 |
71 | GLint CanvasShader::id()
72 | {
73 | return m_shaderId;
74 | }
75 |
76 | bool CanvasShader::isAlive()
77 | {
78 | return bool(m_shaderId);
79 | }
80 |
81 | void CanvasShader::del()
82 | {
83 | if (m_shaderId) {
84 | queueCommand(CanvasGlCommandQueue::glDeleteShader, m_shaderId);
85 | m_shaderId = 0;
86 | }
87 | }
88 |
89 | QString CanvasShader::sourceCode()
90 | {
91 | return m_sourceCode;
92 | }
93 |
94 | void CanvasShader::setSourceCode(const QString &source)
95 | {
96 | m_sourceCode = source;
97 | }
98 |
99 | void CanvasShader::compileShader()
100 | {
101 | if (m_shaderId) {
102 | queueCommand(CanvasGlCommandQueue::glCompileShader, new QByteArray(m_sourceCode.toLatin1()),
103 | m_shaderId);
104 | }
105 | }
106 |
107 | QT_CANVAS3D_END_NAMESPACE
108 | QT_END_NAMESPACE
109 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/shader3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef SHADER3D_P_H
51 | #define SHADER3D_P_H
52 |
53 | #include "context3d_p.h"
54 | #include "abstractobject3d_p.h"
55 |
56 | QT_BEGIN_NAMESPACE
57 | QT_CANVAS3D_BEGIN_NAMESPACE
58 |
59 | class CanvasShader : public CanvasAbstractObject
60 | {
61 | Q_OBJECT
62 | public:
63 | explicit CanvasShader(GLenum type, CanvasGlCommandQueue *queue, QObject *parent);
64 | ~CanvasShader();
65 |
66 | void del();
67 | GLint id();
68 | bool isAlive();
69 | QString sourceCode();
70 | void setSourceCode(const QString &source);
71 | void compileShader();
72 |
73 | private:
74 | GLint m_shaderId;
75 | QString m_sourceCode;
76 | };
77 |
78 | QT_CANVAS3D_END_NAMESPACE
79 | QT_END_NAMESPACE
80 |
81 | #endif // SHADER3D_P_H
82 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/shaderprecisionformat.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | #include "shaderprecisionformat_p.h"
41 |
42 | QT_BEGIN_NAMESPACE
43 | QT_CANVAS3D_BEGIN_NAMESPACE
44 |
45 | /*!
46 | * \qmltype Canvas3DShaderPrecisionFormat
47 | * \since QtCanvas3D 1.0
48 | * \inqmlmodule QtCanvas3D
49 | * \brief Contains the shader precision format attributes.
50 | * \deprecated
51 | *
52 | * \b{Deprecated in Qt 5.12.}
53 | * An uncreatable QML type that contains the information returned from the
54 | * \l{Context3D::getShaderPrecisionFormat()} call.
55 | *
56 | * \sa Context3D
57 | */
58 |
59 | CanvasShaderPrecisionFormat::CanvasShaderPrecisionFormat(QObject *parent) :
60 | CanvasAbstractObject(0, parent)
61 | {
62 | }
63 |
64 | /*!
65 | * \qmlproperty int Canvas3DShaderPrecisionFormat::rangeMin
66 | * \b{Deprecated in Qt 5.12.}
67 | * The base 2 log of the absolute value of the minimum value that can be represented.
68 | */
69 |
70 | /*!
71 | * \qmlproperty int Canvas3DShaderPrecisionFormat::rangeMax
72 | * \b{Deprecated in Qt 5.12.}
73 | * The base 2 log of the absolute value of the maximum value that can be represented.
74 | */
75 |
76 | /*!
77 | * \qmlproperty int Canvas3DShaderPrecisionFormat::precision
78 | * \b{Deprecated in Qt 5.12.}
79 | * The number of bits of precision that can be represented. 0 for integer formats.
80 | */
81 |
82 | QT_CANVAS3D_END_NAMESPACE
83 | QT_END_NAMESPACE
84 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/shaderprecisionformat_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef SHADERPRECISIONFORMAT_P_H
51 | #define SHADERPRECISIONFORMAT_P_H
52 |
53 | #include "abstractobject3d_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class CanvasShaderPrecisionFormat : public CanvasAbstractObject
61 | {
62 | Q_OBJECT
63 | Q_PROPERTY(int rangeMin READ rangeMin NOTIFY rangeMinChanged)
64 | Q_PROPERTY(int rangeMax READ rangeMax NOTIFY rangeMaxChanged)
65 | Q_PROPERTY(int precision READ precision NOTIFY precisionChanged)
66 |
67 | public:
68 | explicit CanvasShaderPrecisionFormat(QObject *parent = 0);
69 |
70 | inline void setRangeMin(int min) { m_rangeMin = min; }
71 | inline void setRangeMax(int max) { m_rangeMax = max; }
72 | inline void setPrecision(int precision) { m_precision = precision; }
73 |
74 | inline int rangeMin() { return m_rangeMin; }
75 | inline int rangeMax() { return m_rangeMax; }
76 | inline int precision() { return m_precision; }
77 |
78 | signals:
79 | void rangeMinChanged(int rangeMin);
80 | void rangeMaxChanged(int rangeMax);
81 | void precisionChanged(int precision);
82 |
83 | private:
84 | int m_rangeMin;
85 | int m_rangeMax;
86 | int m_precision;
87 | };
88 |
89 | QT_CANVAS3D_END_NAMESPACE
90 | QT_END_NAMESPACE
91 |
92 | #endif // SHADERPRECISIONFORMAT_P_H
93 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/texture3d_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef TEXTURE3D_P_H
51 | #define TEXTURE3D_P_H
52 |
53 | #include "context3d_p.h"
54 | #include "abstractobject3d_p.h"
55 | #include
56 |
57 | class QQuickItem;
58 |
59 | QT_BEGIN_NAMESPACE
60 | QT_CANVAS3D_BEGIN_NAMESPACE
61 |
62 | class CanvasTexture : public CanvasAbstractObject
63 | {
64 | Q_OBJECT
65 |
66 | public:
67 | explicit CanvasTexture(CanvasGlCommandQueue *queue, CanvasContext *context,
68 | QQuickItem *quickItem = 0);
69 | ~CanvasTexture();
70 |
71 | void bind(CanvasContext::glEnums target);
72 |
73 | void del();
74 | bool isAlive() const;
75 | GLint textureId() const;
76 |
77 | friend QDebug operator<< (QDebug d, const CanvasTexture *texture);
78 |
79 | public slots:
80 | void handleItemDestroyed();
81 |
82 | private:
83 | GLint m_textureId;
84 | bool m_isAlive;
85 | CanvasContext *m_context;
86 | QQuickItem *m_quickItem;
87 | };
88 |
89 | QT_CANVAS3D_END_NAMESPACE
90 | QT_END_NAMESPACE
91 |
92 | #endif // TEXTURE3D_P_H
93 |
--------------------------------------------------------------------------------
/src/imports/qtcanvas3d/uniformlocation_p.h:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:LGPL$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU Lesser General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU Lesser
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the
21 | ** packaging of this file. Please review the following information to
22 | ** ensure the GNU Lesser General Public License version 3 requirements
23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24 | **
25 | ** GNU General Public License Usage
26 | ** Alternatively, this file may be used under the terms of the GNU
27 | ** General Public License version 2.0 or (at your option) the GNU General
28 | ** Public license version 3 or any later version approved by the KDE Free
29 | ** Qt Foundation. The licenses are as published by the Free Software
30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31 | ** included in the packaging of this file. Please review the following
32 | ** information to ensure the GNU General Public License requirements will
33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34 | ** https://www.gnu.org/licenses/gpl-3.0.html.
35 | **
36 | ** $QT_END_LICENSE$
37 | **
38 | ****************************************************************************/
39 |
40 | //
41 | // W A R N I N G
42 | // -------------
43 | //
44 | // This file is not part of the QtCanvas3D API. It exists purely as an
45 | // implementation detail. This header file may change from version to
46 | // version without notice, or even be removed.
47 | //
48 | // We mean it.
49 |
50 | #ifndef UNIFORMLOCATION_P_H
51 | #define UNIFORMLOCATION_P_H
52 |
53 | #include "abstractobject3d_p.h"
54 |
55 | #include
56 |
57 | QT_BEGIN_NAMESPACE
58 | QT_CANVAS3D_BEGIN_NAMESPACE
59 |
60 | class CanvasContext;
61 |
62 | class CanvasUniformLocation : public CanvasAbstractObject
63 | {
64 | Q_OBJECT
65 |
66 | public:
67 | explicit CanvasUniformLocation(CanvasGlCommandQueue *queue, QObject *parent = 0);
68 | virtual ~CanvasUniformLocation();
69 |
70 | GLint id();
71 | GLint type();
72 | void resolveType(GLint programId, CanvasContext *context);
73 |
74 | friend QDebug operator<< (QDebug d, const CanvasUniformLocation *uLoc);
75 |
76 | private:
77 | GLint m_locationId;
78 | GLint m_type;
79 | };
80 |
81 | QT_CANVAS3D_END_NAMESPACE
82 | QT_END_NAMESPACE
83 |
84 | #endif // UNIFORMLOCATION_P_H
85 |
--------------------------------------------------------------------------------
/src/src.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | CONFIG += ordered
3 |
4 | SUBDIRS += imports
5 |
--------------------------------------------------------------------------------
/sync.profile:
--------------------------------------------------------------------------------
1 | %modules = ( # path to module name map
2 | "QtCanvas3D" => "$basedir/src",
3 | );
4 | %moduleheaders = ( # restrict the module headers to those found in relative path
5 | );
6 |
--------------------------------------------------------------------------------
/tests/auto/auto.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | !uikit: SUBDIRS += qmltest
3 |
4 | installed_cmake.depends = cmake
5 |
6 | # Currently qmltest crashes for boot2qt
7 | boot2qt: SUBDIRS -= qmltest
8 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_attribs.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | import "tst_attribs.js" as Content
34 |
35 | Item {
36 | id: top
37 | height: 300
38 | width: 300
39 |
40 | Canvas3D {
41 | id: attribs_test
42 | property bool heightChanged: false
43 | property bool widthChanged: false
44 | property int initStatus: -1
45 | property int renderStatus: -1
46 |
47 | anchors.fill: parent
48 | onInitializeGL: initStatus = Content.initializeGL(attribs_test)
49 | onPaintGL: {
50 | renderStatus = Content.paintGL(attribs_test)
51 | }
52 | onHeightChanged: heightChanged = true
53 | onWidthChanged: widthChanged = true
54 | }
55 |
56 | TestCase {
57 | name: "Canvas3D_get_active_attrib"
58 | when: windowShown
59 |
60 | function test_attribs() {
61 | waitForRendering(attribs_test)
62 | tryCompare(attribs_test, "initStatus", 0)
63 | tryCompare(attribs_test, "renderStatus", 0)
64 | }
65 | }
66 | }
67 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_creation_aa_context.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | Item {
34 | id: top
35 | height: 150
36 | width: 150
37 |
38 | Canvas3D {
39 | id: aa_context
40 | anchors.fill: parent
41 | property int initStatus: 0
42 | onInitializeGL: {
43 | getContext("antialias", {antialias:true})
44 | initStatus = 1
45 | }
46 | }
47 |
48 | TestCase {
49 | name: "Canvas3D_creation_aa_context"
50 | when: windowShown
51 |
52 | function test_aa_context() {
53 | waitForRendering(aa_context)
54 | tryCompare(aa_context, "initStatus", 1)
55 | compare(aa_context.context.canvas, aa_context)
56 | }
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_creation_depth_context.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | Item {
34 | id: top
35 | height: 150
36 | width: 150
37 |
38 | Canvas3D {
39 | id: depth_context
40 | anchors.fill: parent
41 | property int initStatus: 0
42 | onInitializeGL: {
43 | getContext("depth", {depth:true})
44 | initStatus = 1
45 | }
46 | }
47 |
48 | TestCase {
49 | name: "Canvas3D_creation_depth_context"
50 | when: windowShown
51 |
52 | function test_depth_context() {
53 | waitForRendering(depth_context)
54 | tryCompare(depth_context, "initStatus", 1)
55 | compare(depth_context.context.canvas, depth_context)
56 | }
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_creation_empty.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | Item {
34 | id: top
35 | height: 150
36 | width: 150
37 |
38 | Canvas3D {
39 | id: empty
40 | }
41 |
42 | TestCase {
43 | name: "Canvas3D_creation_empty"
44 | when: windowShown
45 |
46 | function test_empty() {
47 | compare(empty.width, 0)
48 | compare(empty.height, 0)
49 | compare(empty.context, null)
50 | }
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_program.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | import "tst_program.js" as Content
34 |
35 | Item {
36 | id: top
37 | height: 300
38 | width: 300
39 |
40 | property var canvas3d: null
41 | property var activeContent: Content
42 |
43 | function createCanvas() {
44 | canvas3d = Qt.createQmlObject("
45 | import QtQuick 2.2
46 | import QtCanvas3D 1.0
47 | Canvas3D {
48 | property bool heightChanged: false
49 | property bool widthChanged: false
50 | property int initStatus: -1
51 | property int renderStatus: -1
52 |
53 | anchors.fill: parent
54 | onInitializeGL: initStatus = activeContent.initializeGL(canvas3d)
55 | onPaintGL: {
56 | renderStatus = activeContent.paintGL(canvas3d)
57 | }
58 | onHeightChanged: heightChanged = true
59 | onWidthChanged: widthChanged = true
60 | }", top)
61 | canvas3d.anchors.fill = top
62 | }
63 |
64 | TestCase {
65 | name: "Canvas3D_test_program_and_shaders"
66 | when: windowShown
67 |
68 | function test_program_and_shaders() {
69 | createCanvas()
70 | verify(canvas3d !== null)
71 | waitForRendering(canvas3d)
72 | tryCompare(canvas3d, "initStatus", 0)
73 | tryCompare(canvas3d, "renderStatus", 0)
74 | }
75 | }
76 | }
77 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_render_checkresult.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/tests/auto/qmltest/canvas3d/tst_render_checkresult.png
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_render_dynamic_canvas_component.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.1
31 |
32 | import "tst_render_simple.js" as Content
33 |
34 | Canvas3D {
35 | id: canvas3d
36 | anchors.fill: parent
37 |
38 | property var activeContent: Content
39 | property bool initOk: false
40 | property bool renderOk: false
41 | property bool contextLostOk: false
42 | property bool contextRestoredOk: false
43 |
44 | onInitializeGL: {
45 | initOk = activeContent.initializeGL(canvas3d)
46 | }
47 | onPaintGL: {
48 | renderOk = true
49 | activeContent.paintGL(canvas3d)
50 | }
51 | onContextLost: {
52 | contextLostOk = activeContent.checkContextLost();
53 | }
54 |
55 | onContextRestored: {
56 | contextRestoredOk = activeContent.checkContextRestored();
57 | }
58 |
59 | function checkContextLostError() {
60 | return activeContent.checkContextLostError();
61 | }
62 | }
63 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/canvas3d/tst_uniforms.qml:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | import QtQuick 2.2
30 | import QtCanvas3D 1.0
31 | import QtTest 1.0
32 |
33 | import "tst_uniforms.js" as Content
34 |
35 | Item {
36 | id: top
37 | height: 300
38 | width: 300
39 |
40 | Canvas3D {
41 | id: uniforms_test
42 | property bool heightChanged: false
43 | property bool widthChanged: false
44 | property int initStatus: -1
45 | property int renderStatus: -1
46 |
47 | anchors.fill: parent
48 | onInitializeGL: initStatus = Content.initializeGL(uniforms_test)
49 | onPaintGL: {
50 | renderStatus = Content.paintGL(uniforms_test)
51 | }
52 | onHeightChanged: heightChanged = true
53 | onWidthChanged: widthChanged = true
54 | }
55 |
56 | TestCase {
57 | name: "Canvas3D_test_uniforms"
58 | when: windowShown
59 |
60 | function test_uniforms() {
61 | waitForRendering(uniforms_test)
62 | tryCompare(uniforms_test, "initStatus", 0)
63 | tryCompare(uniforms_test, "renderStatus", 0)
64 | }
65 | }
66 | }
67 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/qmltest.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | TARGET = tst_qmltest
4 |
5 | CONFIG += qmltestcase
6 | CONFIG += console
7 |
8 | SOURCES += tst_qmltest.cpp
9 |
10 | OTHER_FILES += canvas3d/tst_*.qml canvas3d/*.js canvas3d/*.png ../../../examples/3rdparty/*.js
11 | DEFINES += QUICK_TEST_SOURCE_DIR=\"\\\"$$PWD/canvas3d\\\"\"
12 |
--------------------------------------------------------------------------------
/tests/auto/qmltest/tst_qmltest.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | #include
30 |
31 | QUICK_TEST_MAIN(qmltest)
32 |
--------------------------------------------------------------------------------
/tests/manual/commandthroughput/commandthroughput.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | SOURCES += main.cpp
6 |
7 | RESOURCES += commandthroughput.qrc
8 |
9 | OTHER_FILES += qml/commandthroughput/*
10 |
11 |
--------------------------------------------------------------------------------
/tests/manual/commandthroughput/commandthroughput.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../../../examples/canvas3d/3rdparty/gl-matrix.js
4 | qml/commandthroughput/commandthroughput.js
5 | qml/commandthroughput/main.qml
6 |
7 |
8 |
--------------------------------------------------------------------------------
/tests/manual/commandthroughput/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | #include
30 | #include
31 | #include
32 | #include
33 |
34 | int main(int argc, char *argv[])
35 | {
36 | QGuiApplication app(argc, argv);
37 |
38 | QQuickView viewer;
39 |
40 | // The following are needed to make app run without having to install the module
41 | // in desktop environments.
42 | #ifdef Q_OS_WIN
43 | QString extraImportPath(QStringLiteral("%1/../../../../%2"));
44 | #else
45 | QString extraImportPath(QStringLiteral("%1/../../../%2"));
46 | #endif
47 | viewer.engine()->addImportPath(extraImportPath.arg(QGuiApplication::applicationDirPath(),
48 | QString::fromLatin1("qml")));
49 |
50 | viewer.setSource(QUrl(QStringLiteral("qrc:///qml/commandthroughput/main.qml")));
51 |
52 | viewer.setTitle(QStringLiteral("Command throughput test"));
53 | viewer.setResizeMode(QQuickView::SizeRootObjectToView);
54 | viewer.show();
55 |
56 | return app.exec();
57 | }
58 |
--------------------------------------------------------------------------------
/tests/manual/manual.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | SUBDIRS = commandthroughput \
3 | multiwindowtest
4 |
--------------------------------------------------------------------------------
/tests/manual/multiwindowtest/main.cpp:
--------------------------------------------------------------------------------
1 | /****************************************************************************
2 | **
3 | ** Copyright (C) 2016 The Qt Company Ltd.
4 | ** Contact: https://www.qt.io/licensing/
5 | **
6 | ** This file is part of the QtCanvas3D module of the Qt Toolkit.
7 | **
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$
9 | ** Commercial License Usage
10 | ** Licensees holding valid commercial Qt licenses may use this file in
11 | ** accordance with the commercial license agreement provided with the
12 | ** Software or, alternatively, in accordance with the terms contained in
13 | ** a written agreement between you and The Qt Company. For licensing terms
14 | ** and conditions see https://www.qt.io/terms-conditions. For further
15 | ** information use the contact form at https://www.qt.io/contact-us.
16 | **
17 | ** GNU General Public License Usage
18 | ** Alternatively, this file may be used under the terms of the GNU
19 | ** General Public License version 3 as published by the Free Software
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
21 | ** included in the packaging of this file. Please review the following
22 | ** information to ensure the GNU General Public License requirements will
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html.
24 | **
25 | ** $QT_END_LICENSE$
26 | **
27 | ****************************************************************************/
28 |
29 | #include
30 | #include
31 |
32 | int main(int argc, char *argv[])
33 | {
34 | QGuiApplication app(argc, argv);
35 |
36 | QQmlApplicationEngine engine;
37 |
38 | engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
39 |
40 | return app.exec();
41 | }
42 |
--------------------------------------------------------------------------------
/tests/manual/multiwindowtest/multiwindowtest.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = app
2 |
3 | QT += qml quick
4 |
5 | SOURCES += main.cpp
6 |
7 | RESOURCES += multiwindowtest.qrc
8 |
9 | OTHER_FILES += qml/multiwindowtest/*
10 |
11 | DISTFILES += \
12 | qml/multiwindowtest/framebuffer.js \
13 | qml/multiwindowtest/quickitemtexture.js \
14 | qml/multiwindowtest/qtlogo.png \
15 | qml/multiwindowtest/framebuffer.qml \
16 | qml/multiwindowtest/quickitemtexture.qml
17 |
18 |
--------------------------------------------------------------------------------
/tests/manual/multiwindowtest/multiwindowtest.qrc:
--------------------------------------------------------------------------------
1 |
2 |
3 | ../../../examples/canvas3d/3rdparty/gl-matrix.js
4 | qml/multiwindowtest/main.qml
5 | qml/multiwindowtest/framebuffer.js
6 | qml/multiwindowtest/framebuffer.qml
7 | qml/multiwindowtest/qtlogo.png
8 | qml/multiwindowtest/quickitemtexture.js
9 | qml/multiwindowtest/quickitemtexture.qml
10 | qml/multiwindowtest/canvaswindow.qml
11 |
12 |
13 |
--------------------------------------------------------------------------------
/tests/manual/multiwindowtest/qml/multiwindowtest/qtlogo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qt/qtcanvas3d/433633fb7285087724d39249060ca10c1dfea9a1/tests/manual/multiwindowtest/qml/multiwindowtest/qtlogo.png
--------------------------------------------------------------------------------
/tests/tests.pro:
--------------------------------------------------------------------------------
1 | TEMPLATE = subdirs
2 | SUBDIRS += auto \
3 | manual
4 |
--------------------------------------------------------------------------------