From 00d139e39f675c32d6b8202900a0d8d5706ee8e3 Mon Sep 17 00:00:00 2001 From: Mike Krus Date: Wed, 22 Feb 2023 11:20:45 +0000 Subject: Move some examples to manual tests Reduces the maintenance burden. Also fixed a few issues when moving code. Pick-to: 6.5 Change-Id: I647f0c1a215f27a0e834d328ca64cfb570639b04 Reviewed-by: Qt CI Bot Reviewed-by: Paul Lemire --- examples/qt3d/audio-visualizer-qml/BarEntity.qml | 155 ------- examples/qt3d/audio-visualizer-qml/CMakeLists.txt | 70 --- examples/qt3d/audio-visualizer-qml/Visualizer.qml | 260 ----------- .../audio-visualizer-qml/audio-visualizer-qml.pro | 20 - .../audio-visualizer-qml/audio-visualizer-qml.qrc | 22 - .../doc/images/audio-visualizer-qml-example.png | Bin 468658 -> 0 bytes .../doc/src/audio-visualizer-qml.qdoc | 64 --- .../audio-visualizer-qml/images/albumcover.png | Bin 627138 -> 0 bytes .../qt3d/audio-visualizer-qml/images/demotitle.png | Bin 7449 -> 0 bytes .../qt3d/audio-visualizer-qml/images/normalmap.png | Bin 308 -> 0 bytes .../images/pausehoverpressed.png | Bin 2017 -> 0 bytes .../audio-visualizer-qml/images/pausenormal.png | Bin 1948 -> 0 bytes .../images/playhoverpressed.png | Bin 2243 -> 0 bytes .../audio-visualizer-qml/images/playnormal.png | Bin 2172 -> 0 bytes .../qt3d/audio-visualizer-qml/images/songtitle.png | Bin 6181 -> 0 bytes .../audio-visualizer-qml/images/stopdisabled.png | Bin 1938 -> 0 bytes .../images/stophoverpressed.png | Bin 2013 -> 0 bytes .../audio-visualizer-qml/images/stopnormal.png | Bin 1939 -> 0 bytes examples/qt3d/audio-visualizer-qml/main.cpp | 42 -- examples/qt3d/audio-visualizer-qml/main.qml | 245 ----------- .../qt3d/audio-visualizer-qml/meshes/circle.obj | 72 ---- .../audio-visualizer-qml/meshes/progressbar.obj | 478 --------------------- .../music/tiltshifted_lost_neon_sun.mp3 | Bin 1014097 -> 0 bytes .../audio-visualizer-qml/music/visualization.raw | Bin 3178 -> 0 bytes .../qt3d/audio-visualizer-qml/touchsettings.cpp | 39 -- examples/qt3d/audio-visualizer-qml/touchsettings.h | 19 - 26 files changed, 1486 deletions(-) delete mode 100644 examples/qt3d/audio-visualizer-qml/BarEntity.qml delete mode 100644 examples/qt3d/audio-visualizer-qml/CMakeLists.txt delete mode 100644 examples/qt3d/audio-visualizer-qml/Visualizer.qml delete mode 100644 examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.pro delete mode 100644 examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.qrc delete mode 100644 examples/qt3d/audio-visualizer-qml/doc/images/audio-visualizer-qml-example.png delete mode 100644 examples/qt3d/audio-visualizer-qml/doc/src/audio-visualizer-qml.qdoc delete mode 100644 examples/qt3d/audio-visualizer-qml/images/albumcover.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/demotitle.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/normalmap.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/pausehoverpressed.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/pausenormal.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/playhoverpressed.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/playnormal.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/songtitle.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/stopdisabled.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/stophoverpressed.png delete mode 100644 examples/qt3d/audio-visualizer-qml/images/stopnormal.png delete mode 100644 examples/qt3d/audio-visualizer-qml/main.cpp delete mode 100644 examples/qt3d/audio-visualizer-qml/main.qml delete mode 100644 examples/qt3d/audio-visualizer-qml/meshes/circle.obj delete mode 100644 examples/qt3d/audio-visualizer-qml/meshes/progressbar.obj delete mode 100644 examples/qt3d/audio-visualizer-qml/music/tiltshifted_lost_neon_sun.mp3 delete mode 100644 examples/qt3d/audio-visualizer-qml/music/visualization.raw delete mode 100644 examples/qt3d/audio-visualizer-qml/touchsettings.cpp delete mode 100644 examples/qt3d/audio-visualizer-qml/touchsettings.h (limited to 'examples/qt3d/audio-visualizer-qml') diff --git a/examples/qt3d/audio-visualizer-qml/BarEntity.qml b/examples/qt3d/audio-visualizer-qml/BarEntity.qml deleted file mode 100644 index 303ac0d3f..000000000 --- a/examples/qt3d/audio-visualizer-qml/BarEntity.qml +++ /dev/null @@ -1,155 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -import Qt3D.Core 2.0 -import Qt3D.Render 2.0 -import Qt3D.Extras 2.0 -import QtQuick 2.4 as QQ2 - -Entity { - property int rotationTimeMs: 0 - property int entityIndex: 0 - property int entityCount: 0 - property int startAngle: 0 + 360 / entityCount * entityIndex - property bool needsNewMagnitude: true - property real magnitude: 0 - property real animWeight: 0 - - property color lowColor: "black" - property color highColor: "#b3b3b3" - property color barColor: lowColor - - property string entityAnimationsState: "stopped" - property bool entityAnimationsPlaying: true - - property var entityMesh: null - - onEntityAnimationsStateChanged: { - if (animationState == "paused") { - if (angleAnimation.running) - angleAnimation.pause() - if (barColorAnimations.running) - barColorAnimations.pause() - } else if (animationState == "playing"){ - needsNewMagnitude = true; - if (heightDecreaseAnimation.running) - heightDecreaseAnimation.stop() - if (angleAnimation.paused) { - angleAnimation.resume() - } else if (!entityAnimationsPlaying) { - magnitude = 0 - angleAnimation.start() - entityAnimationsPlaying = true - } - if (barColorAnimations.paused) - barColorAnimations.resume() - } else { - if (animWeight != 0) - heightDecreaseAnimation.start() - needsNewMagnitude = true - angleAnimation.stop() - barColorAnimations.stop() - entityAnimationsPlaying = false - } - } - - property Material barMaterial: PhongMaterial { - diffuse: barColor - ambient: Qt.darker(barColor) - specular: "black" - shininess: 1 - } - - property Transform angleTransform: Transform { - property real heightIncrease: magnitude * animWeight - property real barAngle: startAngle - - matrix: { - var m = Qt.matrix4x4() - m.rotate(barAngle, Qt.vector3d(0, 1, 0)) - m.translate(Qt.vector3d(1.1, heightIncrease / 2 - heightIncrease * 0.05, 0)) - m.scale(Qt.vector3d(0.5, heightIncrease * 15, 0.5)) - return m; - } - - property real compareAngle: barAngle - onBarAngleChanged: { - compareAngle = barAngle - - if (compareAngle > 360) - compareAngle = barAngle - 360 - - if (compareAngle > 180) { - parent.enabled = false - animWeight = 0 - if (needsNewMagnitude) { - // Calculate the ms offset where the bar will be at the center point of the - // visualization and fetch the correct magnitude for that point in time. - var offset = (90.0 + 360.0 - compareAngle) * (rotationTimeMs / 360.0) - magnitude = mediaPlayer.getNextAudioLevel(offset) - needsNewMagnitude = false - } - } else { - parent.enabled = true - // Calculate a power of 2 curve for the bar animation that peaks at 90 degrees - animWeight = Math.min((compareAngle / 90), (180 - compareAngle) / 90) - animWeight = animWeight * animWeight - if (!needsNewMagnitude) { - needsNewMagnitude = true - barColorAnimations.start() - } - } - } - } - - components: [entityMesh, barMaterial, angleTransform] - - //![0] - QQ2.NumberAnimation { - id: angleAnimation - target: angleTransform - property: "barAngle" - duration: rotationTimeMs - loops: QQ2.Animation.Infinite - running: true - from: startAngle - to: 360 + startAngle - } - //![0] - - QQ2.NumberAnimation { - id: heightDecreaseAnimation - target: angleTransform - property: "heightIncrease" - duration: 400 - running: false - from: angleTransform.heightIncrease - to: 0 - onStopped: barColor = lowColor - } - - property int animationDuration: angleAnimation.duration / 6 - - //![1] - QQ2.SequentialAnimation on barColor { - id: barColorAnimations - running: false - - QQ2.ColorAnimation { - from: lowColor - to: highColor - duration: animationDuration - } - - QQ2.PauseAnimation { - duration: animationDuration - } - - QQ2.ColorAnimation { - from: highColor - to: lowColor - duration: animationDuration - } - } - //![1] -} diff --git a/examples/qt3d/audio-visualizer-qml/CMakeLists.txt b/examples/qt3d/audio-visualizer-qml/CMakeLists.txt deleted file mode 100644 index 0d06f0abd..000000000 --- a/examples/qt3d/audio-visualizer-qml/CMakeLists.txt +++ /dev/null @@ -1,70 +0,0 @@ -# Copyright (C) 2022 The Qt Company Ltd. -# SPDX-License-Identifier: BSD-3-Clause - -cmake_minimum_required(VERSION 3.16) -project(audio-visualizer-qml LANGUAGES CXX) - -set(CMAKE_AUTOMOC ON) - -if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") -endif() - -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}") - -find_package(Qt6 REQUIRED COMPONENTS 3DCore 3DQuick Core Gui Multimedia Qml Quick) - -qt_add_executable(audio-visualizer-qml - main.cpp - touchsettings.cpp touchsettings.h -) - -set_target_properties(audio-visualizer-qml PROPERTIES - WIN32_EXECUTABLE TRUE - MACOSX_BUNDLE TRUE -) - -target_link_libraries(audio-visualizer-qml PUBLIC - Qt::3DCore - Qt::3DQuick - Qt::Core - Qt::Gui - Qt::Multimedia - Qt::Qml - Qt::Quick -) - -# Resources: -set(audio-visualizer-qml_resource_files - "BarEntity.qml" - "Visualizer.qml" - "images/albumcover.png" - "images/demotitle.png" - "images/normalmap.png" - "images/pausehoverpressed.png" - "images/pausenormal.png" - "images/playhoverpressed.png" - "images/playnormal.png" - "images/songtitle.png" - "images/stopdisabled.png" - "images/stophoverpressed.png" - "images/stopnormal.png" - "main.qml" - "meshes/circle.obj" - "meshes/progressbar.obj" - "music/tiltshifted_lost_neon_sun.mp3" - "music/visualization.raw" -) - -qt6_add_resources(audio-visualizer-qml "audio-visualizer-qml" - PREFIX - "/" - FILES - ${audio-visualizer-qml_resource_files} -) - -install(TARGETS audio-visualizer-qml - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" -) diff --git a/examples/qt3d/audio-visualizer-qml/Visualizer.qml b/examples/qt3d/audio-visualizer-qml/Visualizer.qml deleted file mode 100644 index 1b4ccec0e..000000000 --- a/examples/qt3d/audio-visualizer-qml/Visualizer.qml +++ /dev/null @@ -1,260 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -import Qt3D.Core 2.0 -import Qt3D.Render 2.0 -import Qt3D.Extras 2.0 -import QtQuick 2.2 as QQ2 - -Entity { - id: sceneRoot - property int barRotationTimeMs: 1 - property int numberOfBars: 1 - property string animationState - property real titleStartAngle: 95 - property real titleStopAngle: 5 - property bool started: false - - onAnimationStateChanged: { - if (animationState == "playing") { - mediaPlayer.play() - if (progressTransformAnimation.paused) - progressTransformAnimation.resume() - else - progressTransformAnimation.start() - } else if (animationState == "paused") { - mediaPlayer.pause() - if (progressTransformAnimation.running) - progressTransformAnimation.pause() - } else { - mediaPlayer.stop() - progressTransformAnimation.stop() - progressTransform.progressAngle = progressTransform.defaultStartAngle - } - } - - QQ2.Item { - id: stateItem - - state: animationState - states: [ - QQ2.State { - name: "playing" - QQ2.PropertyChanges { - target: titlePrism - titleAngle: titleStopAngle - } - }, - QQ2.State { - name: "paused" - QQ2.PropertyChanges { - target: titlePrism - titleAngle: titleStopAngle - } - }, - QQ2.State { - name: "stopped" - QQ2.PropertyChanges { - target: titlePrism - titleAngle: titleStartAngle - } - } - ] - - transitions: QQ2.Transition { - QQ2.NumberAnimation { - property: "titleAngle" - duration: 2000 - running: false - } - } - } - - function startVisualization() { - progressTransformAnimation.duration = mediaPlayer.duration - mainview.state = "playing" - progressTransformAnimation.start() - started = true - } - - //![0] - Camera { - id: camera - projectionType: CameraLens.PerspectiveProjection - fieldOfView: 45 - aspectRatio: 1820 / 1080 - nearPlane: 0.1 - farPlane: 1000.0 - position: Qt.vector3d(0.014, 0.956, 2.178) - upVector: Qt.vector3d(0.0, 1.0, 0.0) - viewCenter: Qt.vector3d(0.0, 0.7, 0.0) - } - //![0] - - Entity { - components: [ - DirectionalLight { - intensity: 0.9 - worldDirection: Qt.vector3d(0, 0.6, -1) - } - ] - } - - RenderSettings { - id: external_forward_renderer - activeFrameGraph: ForwardRenderer { - camera: camera - clearColor: "transparent" - } - } - - components: [external_forward_renderer] - - //![1] - // Bars - CuboidMesh { - id: barMesh - xExtent: 0.1 - yExtent: 0.1 - zExtent: 0.1 - } - - NodeInstantiator { - id: collection - property int maxCount: parent.numberOfBars - model: maxCount - - delegate: BarEntity { - id: cubicEntity - entityMesh: barMesh - rotationTimeMs: sceneRoot.barRotationTimeMs - entityIndex: index - entityCount: sceneRoot.numberOfBars - entityAnimationsState: animationState - magnitude: 0 - } - } - //![1] - - // TitlePrism - Entity { - id: titlePrism - property real titleAngle: titleStartAngle - - Entity { - id: titlePlane - - PlaneMesh { - id: titlePlaneMesh - width: 550 - height: 100 - } - - Transform { - id: titlePlaneTransform - scale: 0.003 - translation: Qt.vector3d(0, 0.11, 0) - } - - NormalDiffuseMapAlphaMaterial { - id: titlePlaneMaterial - diffuse: TextureLoader { source: "qrc:/images/demotitle.png" } - normal: TextureLoader { source: "qrc:/images/normalmap.png" } - shininess: 1.0 - } - - components: [titlePlaneMesh, titlePlaneMaterial, titlePlaneTransform] - } - - // Song title - Entity { - id: songTitlePlane - - PlaneMesh { - id: songPlaneMesh - width: 550 - height: 100 - } - - Transform { - id: songPlaneTransform - scale: 0.003 - rotationX: 90 - translation: Qt.vector3d(0, -0.03, 0.13) - } - - property Material songPlaneMaterial: NormalDiffuseMapAlphaMaterial { - diffuse: TextureLoader { source: "qrc:/images/songtitle.png" } - normal: TextureLoader { source: "qrc:/images/normalmap.png" } - shininess: 1.0 - } - - components: [songPlaneMesh, songPlaneMaterial, songPlaneTransform] - } - - property Transform titlePrismPlaneTransform: Transform { - matrix: { - var m = Qt.matrix4x4() - m.translate(Qt.vector3d(-0.5, 1.3, -0.4)) - m.rotate(titlePrism.titleAngle, Qt.vector3d(1, 0, 0)) - return m; - } - } - - components: [titlePlane, songTitlePlane, titlePrismPlaneTransform] - } - - // Circle to create the reflection effect - Mesh { - id: circleMesh - source: "qrc:/meshes/circle.obj" - } - - Entity { - id: circleEntity - property Material circleMaterial: PhongAlphaMaterial { - alpha: 0.4 - ambient: "black" - diffuse: "black" - specular: "black" - shininess: 10000 - } - - components: [circleMesh, circleMaterial] - } - - //![2] - // Progress - Mesh { - id: progressMesh - source: "qrc:/meshes/progressbar.obj" - } - - Transform { - id: progressTransform - property real defaultStartAngle: -90 - property real progressAngle: defaultStartAngle - rotationY: progressAngle - } - - Entity { - property Material progressMaterial: PhongMaterial { - ambient: "#80C342" - diffuse: "black" - } - - components: [progressMesh, progressMaterial, progressTransform] - } - //![2] - - QQ2.NumberAnimation { - id: progressTransformAnimation - target: progressTransform - property: "progressAngle" - duration: 0 - running: false - from: progressTransform.defaultStartAngle - to: -270 - onStopped: if (animationState != "stopped") animationState = "stopped" - } -} diff --git a/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.pro b/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.pro deleted file mode 100644 index b2c3c7f2e..000000000 --- a/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.pro +++ /dev/null @@ -1,20 +0,0 @@ -requires(qtHaveModule(multimedia)) - -!include( ../examples.pri ) { - error( "Couldn't find the examples.pri file!" ) -} - -QT += 3dcore 3dquick qml quick multimedia - -SOURCES += \ - main.cpp \ - touchsettings.cpp - -HEADERS += \ - touchsettings.h - -OTHER_FILES += \ - *.qml - -RESOURCES += \ - audio-visualizer-qml.qrc diff --git a/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.qrc b/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.qrc deleted file mode 100644 index fb8324cb6..000000000 --- a/examples/qt3d/audio-visualizer-qml/audio-visualizer-qml.qrc +++ /dev/null @@ -1,22 +0,0 @@ - - - main.qml - Visualizer.qml - BarEntity.qml - meshes/circle.obj - meshes/progressbar.obj - images/pausenormal.png - images/playnormal.png - images/stopdisabled.png - images/stopnormal.png - images/pausehoverpressed.png - images/playhoverpressed.png - images/stophoverpressed.png - music/tiltshifted_lost_neon_sun.mp3 - images/demotitle.png - images/songtitle.png - images/normalmap.png - images/albumcover.png - music/visualization.raw - - diff --git a/examples/qt3d/audio-visualizer-qml/doc/images/audio-visualizer-qml-example.png b/examples/qt3d/audio-visualizer-qml/doc/images/audio-visualizer-qml-example.png deleted file mode 100644 index d84efd464..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/doc/images/audio-visualizer-qml-example.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/doc/src/audio-visualizer-qml.qdoc b/examples/qt3d/audio-visualizer-qml/doc/src/audio-visualizer-qml.qdoc deleted file mode 100644 index 28a4adbb2..000000000 --- a/examples/qt3d/audio-visualizer-qml/doc/src/audio-visualizer-qml.qdoc +++ /dev/null @@ -1,64 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only - -/*! - \example audio-visualizer-qml - \title Qt 3D: Audio Visualizer Example - \ingroup qt3d-examples-qml - \brief Demonstrates combining Qt 3D rendering and Qt Quick 2 elements. - - \image audio-visualizer-qml-example.png - - \e Audio Visualizer demonstrates how to implement an application that combines the use of - Qt 3D rendering with Qt Quick 2D elements. The example uses media player to play music and it - visualizes the magnitude of the music as animated bars. - - \include examples-run.qdocinc - - \section1 Qt Quick 2D Implementation - - The Qt Quick Implementation in \c {audio-visualizer-qml/main.qml} of the example uses - \c{MediaPlayer} to play audio content. - - \snippet audio-visualizer-qml/main.qml 0 - - The player is controlled with the \c{playButton} and c\{stopButton}. Based on the clicked - buttons the \c{state} of the \c{mainview} changes. - - The 3D content is rendered using the \c{Scene3D} type. The state of the Audio Visualizer is - maintained in the \c{mainview}. It's passed on to the \c{visualizer} as it's needed for the bar - animations. - - \snippet audio-visualizer-qml/main.qml 1 - - \section1 Qt 3D Implementation - - The 3D elements of the example are created in - \c {audio-visualizer-qml/Visualizer.qml}. The camera is set to a fixed position - to show the visualized bars from a correct angle. - - \snippet audio-visualizer-qml/Visualizer.qml 0 - - A \c{NodeInstantiator} is used to create the bars that visualize the magnitude of the music. - - \snippet audio-visualizer-qml/Visualizer.qml 1 - - The \c{visualizer} also contains an \c{Entity} to show the progress. This element has a curve - shaped mesh and it's rotated on a level to show the progress based on the duration of the played - track. - - \snippet audio-visualizer-qml/Visualizer.qml 2 - - In \c {audio-visualizer-qml/BarEntity.qml} there are animations for rotating the - bars and changing the bar color. The bars are rotated on a level following a ring form. At the - same time the color of the bars is animated. - - \snippet audio-visualizer-qml/BarEntity.qml 0 - - \snippet audio-visualizer-qml/BarEntity.qml 1 - - The magnitude of each bar is read from a separate .raw file that is based on the track being - played. As the bars rotate around the ring the height is scaled to highlight currently played - position. After a full round of rotation, a new value is fetched for the bar. - -*/ diff --git a/examples/qt3d/audio-visualizer-qml/images/albumcover.png b/examples/qt3d/audio-visualizer-qml/images/albumcover.png deleted file mode 100644 index 89872564f..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/albumcover.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/demotitle.png b/examples/qt3d/audio-visualizer-qml/images/demotitle.png deleted file mode 100644 index 75c6c42bd..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/demotitle.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/normalmap.png b/examples/qt3d/audio-visualizer-qml/images/normalmap.png deleted file mode 100644 index 0c3941c4e..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/normalmap.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/pausehoverpressed.png b/examples/qt3d/audio-visualizer-qml/images/pausehoverpressed.png deleted file mode 100644 index 1a2c585fe..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/pausehoverpressed.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/pausenormal.png b/examples/qt3d/audio-visualizer-qml/images/pausenormal.png deleted file mode 100644 index 50c46ab36..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/pausenormal.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/playhoverpressed.png b/examples/qt3d/audio-visualizer-qml/images/playhoverpressed.png deleted file mode 100644 index a65e74501..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/playhoverpressed.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/playnormal.png b/examples/qt3d/audio-visualizer-qml/images/playnormal.png deleted file mode 100644 index 546bdd2b3..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/playnormal.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/songtitle.png b/examples/qt3d/audio-visualizer-qml/images/songtitle.png deleted file mode 100644 index 84efe533a..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/songtitle.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/stopdisabled.png b/examples/qt3d/audio-visualizer-qml/images/stopdisabled.png deleted file mode 100644 index 06e3672f0..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/stopdisabled.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/stophoverpressed.png b/examples/qt3d/audio-visualizer-qml/images/stophoverpressed.png deleted file mode 100644 index 67d2db299..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/stophoverpressed.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/images/stopnormal.png b/examples/qt3d/audio-visualizer-qml/images/stopnormal.png deleted file mode 100644 index ddb15509c..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/images/stopnormal.png and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/main.cpp b/examples/qt3d/audio-visualizer-qml/main.cpp deleted file mode 100644 index 6b3237fdd..000000000 --- a/examples/qt3d/audio-visualizer-qml/main.cpp +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -#include "touchsettings.h" -#include -#include -#include -#include -#include - -int main(int argc, char* argv[]) -{ - qputenv("QML_XHR_ALLOW_FILE_READ", "1"); -#ifdef Q_OS_ANDROID - QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling); -#endif - QGuiApplication app(argc, argv); - - QSurfaceFormat format; - if (QOpenGLContext::openGLModuleType() == QOpenGLContext::LibGL) { - format.setVersion(3, 2); - format.setProfile(QSurfaceFormat::CoreProfile); - } - format.setDepthBufferSize(24); - format.setStencilBufferSize(8); - - QQuickView view; - view.setFormat(format); - view.create(); - - TouchSettings touchSettings; - view.rootContext()->setContextProperty("touchSettings", &touchSettings); - - view.setSource(QUrl("qrc:/main.qml")); - - view.setResizeMode(QQuickView::SizeRootObjectToView); - view.setMaximumSize(QSize(1820, 1080)); - view.setMinimumSize(QSize(300, 150)); - view.show(); - - return app.exec(); -} diff --git a/examples/qt3d/audio-visualizer-qml/main.qml b/examples/qt3d/audio-visualizer-qml/main.qml deleted file mode 100644 index 49c26106b..000000000 --- a/examples/qt3d/audio-visualizer-qml/main.qml +++ /dev/null @@ -1,245 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -import QtQuick -import QtQuick.Scene3D -import QtQuick.Layouts -import QtMultimedia - -Item { - id: mainview - width: 1215 - height: 720 - visible: true - property bool isHoverEnabled: false - - property variant magnitudeArray: null - property int millisecondsPerBar: 68 - property string magnitudeDataSourceFile: "qrc:/music/visualization.raw" - property int mediaLatencyOffset: 68 - - state: "stopped" - states: [ - State { - name: "playing" - PropertyChanges { - target: playButtonImage - source: { - if (playButtonMouseArea.containsMouse) - "qrc:/images/pausehoverpressed.png" - else - "qrc:/images/pausenormal.png" - } - } - PropertyChanges { - target: stopButtonImage - source: "qrc:/images/stopnormal.png" - } - }, - State { - name: "paused" - PropertyChanges { - target: playButtonImage - source: { - if (playButtonMouseArea.containsMouse) - "qrc:/images/playhoverpressed.png" - else - "qrc:/images/playnormal.png" - } - } - PropertyChanges { - target: stopButtonImage - source: "qrc:/images/stopnormal.png" - } - }, - State { - name: "stopped" - PropertyChanges { - target: playButtonImage - source: "qrc:/images/playnormal.png" - } - PropertyChanges { - target: stopButtonImage - source: "qrc:/images/stopdisabled.png" - } - } - ] - - Component.onCompleted: isHoverEnabled = touchSettings.isHoverEnabled() - - //![0] - MediaPlayer { - id: mediaPlayer - source: "qrc:/music/tiltshifted_lost_neon_sun.mp3" - audioOutput: AudioOutput {} - //![0] - - onMediaStatusChanged: { - if (mediaStatus == MediaPlayer.EndOfMedia) { - mainview.state = "stopped" - } else if (mediaStatus == MediaPlayer.LoadedMedia && !visualizer.started) { - // Load the pre-calculated magnitude data for the visualizer - var request = new XMLHttpRequest() - request.responseType = 'arraybuffer' - request.onreadystatechange = function() { - if (request.readyState === XMLHttpRequest.DONE) { - if (request.status == 200 || request.status == 0) { - var arrayBuffer = request.response - if (arrayBuffer) { - magnitudeArray = new Uint16Array(arrayBuffer) - visualizer.startVisualization() - } - } else { - console.warn("Couldn't load magnitude data for bars.") - } - request = null - } - }; - - request.open('GET', magnitudeDataSourceFile, true) - request.send(null) - } - } - - onErrorStringChanged: console.error("error with audio " + errorString) - - function getNextAudioLevel(offsetMs) { - if (magnitudeArray === null) - return 0.0; - - // Calculate the integer index position in to the magnitude array - var index = ((mediaPlayer.position + offsetMs) / - mainview.millisecondsPerBar) | 0; - - if (index < 0 || index >= magnitudeArray.length) - return 0.0; - - return (magnitudeArray[index] / 63274.0); - } - } - - Image { - id: coverImage - anchors.fill: parent - source: "qrc:/images/albumcover.png" - } - - //![1] - Scene3D { - anchors.fill: parent - - Visualizer { - id: visualizer - animationState: mainview.state - numberOfBars: 120 - barRotationTimeMs: 8160 // 68 ms per bar - } - } - //![1] - - Rectangle { - id: blackBottomRect - color: "black" - width: parent.width - height: 0.14 * mainview.height - anchors.bottom: parent.bottom - } - - // Duration of played content - Text { - text: formatDuration(mediaPlayer.position) - color: "#80C342" - x: parent.width / 6 - y: mainview.height - mainview.height / 8 - font.pixelSize: 12 - } - - // Duration of the content left - Text { - text: "-" + formatDuration(mediaPlayer.duration - mediaPlayer.position) - color: "#80C342" - x: parent.width - parent.width / 6 - y: mainview.height - mainview.height / 8 - font.pixelSize: 12 - } - - function formatDuration(milliseconds) { - var minutes = Math.floor(milliseconds / 60000) - milliseconds -= minutes * 60000 - var seconds = milliseconds / 1000 - seconds = Math.round(seconds) - if (seconds < 10) - return minutes + ":0" + seconds - else - return minutes + ":" + seconds - } - - property int buttonHorizontalMargin: 10 - Rectangle { - id: playButton - height: 54 - width: 54 - anchors.bottom: parent.bottom - anchors.bottomMargin: width - x: parent.width / 2 - width - buttonHorizontalMargin - color: "transparent" - - Image { - id: playButtonImage - source: "qrc:/images/pausenormal.png" - } - - MouseArea { - id: playButtonMouseArea - anchors.fill: parent - hoverEnabled: isHoverEnabled - onClicked: { - if (mainview.state == 'paused' || mainview.state == 'stopped') - mainview.state = 'playing' - else - mainview.state = 'paused' - } - onEntered: { - if (mainview.state == 'playing') - playButtonImage.source = "qrc:/images/pausehoverpressed.png" - else - playButtonImage.source = "qrc:/images/playhoverpressed.png" - } - onExited: { - if (mainview.state == 'playing') - playButtonImage.source = "qrc:/images/pausenormal.png" - else - playButtonImage.source = "qrc:/images/playnormal.png" - } - } - } - - Rectangle { - id: stopButton - height: 54 - width: 54 - anchors.bottom: parent.bottom - anchors.bottomMargin: width - x: parent.width / 2 + buttonHorizontalMargin - color: "transparent" - - Image { - id: stopButtonImage - source: "qrc:/images/stopnormal.png" - } - - MouseArea { - anchors.fill: parent - hoverEnabled: isHoverEnabled - onClicked: mainview.state = 'stopped' - onEntered: { - if (mainview.state != 'stopped') - stopButtonImage.source = "qrc:/images/stophoverpressed.png" - } - onExited: { - if (mainview.state != 'stopped') - stopButtonImage.source = "qrc:/images/stopnormal.png" - } - } - } -} diff --git a/examples/qt3d/audio-visualizer-qml/meshes/circle.obj b/examples/qt3d/audio-visualizer-qml/meshes/circle.obj deleted file mode 100644 index e76bc8659..000000000 --- a/examples/qt3d/audio-visualizer-qml/meshes/circle.obj +++ /dev/null @@ -1,72 +0,0 @@ -# Blender v2.76 (sub 0) OBJ File: '' -# www.blender.org -mtllib circle.mtl -o Circle -v 0.000000 0.000000 0.000000 -v 0.000000 0.000000 -1.100000 -v -0.214599 0.000000 -1.078864 -v -0.420952 0.000000 -1.016267 -v -0.611127 0.000000 -0.914617 -v -0.777817 0.000000 -0.777817 -v -0.914617 0.000000 -0.611127 -v -1.016267 0.000000 -0.420952 -v -1.078864 0.000000 -0.214599 -v -1.100000 0.000000 -0.000000 -v -1.078864 0.000000 0.214599 -v -1.016268 0.000000 0.420952 -v -0.914617 0.000000 0.611127 -v -0.777817 0.000000 0.777817 -v -0.611127 0.000000 0.914617 -v -0.420952 0.000000 1.016268 -v -0.214599 0.000000 1.078864 -v 0.000000 0.000000 1.100000 -v 0.214600 0.000000 1.078864 -v 0.420952 0.000000 1.016267 -v 0.611128 0.000000 0.914616 -v 0.777818 0.000000 0.777817 -v 0.914617 0.000000 0.611127 -v 1.016268 0.000000 0.420951 -v 1.078864 0.000000 0.214598 -v 1.100000 0.000000 -0.000001 -v 1.078864 0.000000 -0.214600 -v 1.016267 0.000000 -0.420953 -v 0.914616 0.000000 -0.611128 -v 0.777816 0.000000 -0.777818 -v 0.611126 0.000000 -0.914617 -v 0.420950 0.000000 -1.016268 -v 0.214598 0.000000 -1.078864 -vn 0.000000 1.000000 0.000000 -usemtl None -s off -f 1//1 2//1 3//1 -f 1//1 3//1 4//1 -f 1//1 4//1 5//1 -f 1//1 5//1 6//1 -f 1//1 6//1 7//1 -f 1//1 7//1 8//1 -f 1//1 8//1 9//1 -f 1//1 9//1 10//1 -f 1//1 10//1 11//1 -f 1//1 11//1 12//1 -f 1//1 12//1 13//1 -f 1//1 13//1 14//1 -f 1//1 14//1 15//1 -f 1//1 15//1 16//1 -f 1//1 16//1 17//1 -f 1//1 17//1 18//1 -f 1//1 18//1 19//1 -f 1//1 19//1 20//1 -f 1//1 20//1 21//1 -f 1//1 21//1 22//1 -f 1//1 22//1 23//1 -f 1//1 23//1 24//1 -f 1//1 24//1 25//1 -f 1//1 25//1 26//1 -f 1//1 26//1 27//1 -f 1//1 27//1 28//1 -f 1//1 28//1 29//1 -f 1//1 29//1 30//1 -f 1//1 30//1 31//1 -f 1//1 31//1 32//1 -f 1//1 32//1 33//1 -f 1//1 33//1 2//1 diff --git a/examples/qt3d/audio-visualizer-qml/meshes/progressbar.obj b/examples/qt3d/audio-visualizer-qml/meshes/progressbar.obj deleted file mode 100644 index a48ad3540..000000000 --- a/examples/qt3d/audio-visualizer-qml/meshes/progressbar.obj +++ /dev/null @@ -1,478 +0,0 @@ -# Blender v2.70 (sub 0) OBJ File: '' -# www.blender.org -v 0.000000 -0.005000 -1.000000 -v 0.000000 0.005000 -1.000000 -v 0.049068 -0.005000 -0.998795 -v 0.049068 0.005000 -0.998795 -v 0.098017 -0.005000 -0.995185 -v 0.098017 0.005000 -0.995185 -v 0.146730 -0.005000 -0.989177 -v 0.146730 0.005000 -0.989177 -v 0.195090 -0.005000 -0.980785 -v 0.195090 0.005000 -0.980785 -v 0.242980 -0.005000 -0.970031 -v 0.242980 0.005000 -0.970031 -v 0.290285 -0.005000 -0.956940 -v 0.290285 0.005000 -0.956940 -v 0.336890 -0.005000 -0.941544 -v 0.336890 0.005000 -0.941544 -v 0.382683 -0.005000 -0.923880 -v 0.382683 0.005000 -0.923880 -v 0.427555 -0.005000 -0.903989 -v 0.427555 0.005000 -0.903989 -v 0.471397 -0.005000 -0.881921 -v 0.471397 0.005000 -0.881921 -v 0.514103 -0.005000 -0.857729 -v 0.514103 0.005000 -0.857729 -v 0.555570 -0.005000 -0.831470 -v 0.555570 0.005000 -0.831470 -v 0.595699 -0.005000 -0.803208 -v 0.595699 0.005000 -0.803208 -v 0.634393 -0.005000 -0.773010 -v 0.634393 0.005000 -0.773010 -v 0.671559 -0.005000 -0.740951 -v 0.671559 0.005000 -0.740951 -v 0.707107 -0.005000 -0.707107 -v 0.707107 0.005000 -0.707107 -v 0.740951 -0.005000 -0.671559 -v 0.740951 0.005000 -0.671559 -v 0.773011 -0.005000 -0.634393 -v 0.773011 0.005000 -0.634393 -v 0.803208 -0.005000 -0.595699 -v 0.803208 0.005000 -0.595699 -v 0.831470 -0.005000 -0.555570 -v 0.831470 0.005000 -0.555570 -v 0.857729 -0.005000 -0.514103 -v 0.857729 0.005000 -0.514103 -v 0.881921 -0.005000 -0.471397 -v 0.881921 0.005000 -0.471397 -v 0.903989 -0.005000 -0.427555 -v 0.903989 0.005000 -0.427555 -v 0.923880 -0.005000 -0.382683 -v 0.923880 0.005000 -0.382683 -v 0.941544 -0.005000 -0.336890 -v 0.941544 0.005000 -0.336890 -v 0.956940 -0.005000 -0.290284 -v 0.956940 0.005000 -0.290284 -v 0.970031 -0.005000 -0.242980 -v 0.970031 0.005000 -0.242980 -v 0.980785 -0.005000 -0.195090 -v 0.980785 0.005000 -0.195090 -v 0.989177 -0.005000 -0.146730 -v 0.989177 0.005000 -0.146730 -v 0.995185 -0.005000 -0.098017 -v 0.995185 0.005000 -0.098017 -v 0.998795 -0.005000 -0.049067 -v 0.998795 0.005000 -0.049067 -v 1.000000 -0.005000 0.000000 -v 1.000000 0.005000 0.000000 -v 0.998795 -0.005000 0.049068 -v 0.998795 0.005000 0.049068 -v 0.995185 -0.005000 0.098018 -v 0.995185 0.005000 0.098018 -v 0.989176 -0.005000 0.146731 -v 0.989176 0.005000 0.146731 -v 0.980785 -0.005000 0.195091 -v 0.980785 0.005000 0.195091 -v 0.970031 -0.005000 0.242981 -v 0.970031 0.005000 0.242981 -v 0.956940 -0.005000 0.290285 -v 0.956940 0.005000 0.290285 -v 0.941544 -0.005000 0.336890 -v 0.941544 0.005000 0.336890 -v 0.923879 -0.005000 0.382684 -v 0.923879 0.005000 0.382684 -v 0.903989 -0.005000 0.427556 -v 0.903989 0.005000 0.427556 -v 0.881921 -0.005000 0.471397 -v 0.881921 0.005000 0.471397 -v 0.857728 -0.005000 0.514103 -v 0.857728 0.005000 0.514103 -v 0.831470 -0.005000 0.555570 -v 0.831470 0.005000 0.555570 -v 0.803208 -0.005000 0.595699 -v 0.803208 0.005000 0.595699 -v 0.773010 -0.005000 0.634393 -v 0.773010 0.005000 0.634393 -v 0.740951 -0.005000 0.671559 -v 0.740951 0.005000 0.671559 -v 0.707107 -0.005000 0.707107 -v 0.707107 0.005000 0.707107 -v 0.671559 -0.005000 0.740951 -v 0.671559 0.005000 0.740951 -v 0.634394 -0.005000 0.773010 -v 0.634394 0.005000 0.773010 -v 0.595700 -0.005000 0.803207 -v 0.595700 0.005000 0.803207 -v 0.555571 -0.005000 0.831469 -v 0.555571 0.005000 0.831469 -v 0.514103 -0.005000 0.857728 -v 0.514103 0.005000 0.857728 -v 0.471397 -0.005000 0.881921 -v 0.471397 0.005000 0.881921 -v 0.427556 -0.005000 0.903989 -v 0.427556 0.005000 0.903989 -v 0.382684 -0.005000 0.923879 -v 0.382684 0.005000 0.923879 -v 0.336891 -0.005000 0.941544 -v 0.336891 0.005000 0.941544 -v 0.290286 -0.005000 0.956940 -v 0.290286 0.005000 0.956940 -v 0.242981 -0.005000 0.970031 -v 0.242981 0.005000 0.970031 -v 0.195092 -0.005000 0.980785 -v 0.195092 0.005000 0.980785 -v 0.146732 -0.005000 0.989176 -v 0.146732 0.005000 0.989176 -v 0.098019 -0.005000 0.995185 -v 0.098019 0.005000 0.995185 -v 0.049069 -0.005000 0.998795 -v 0.049069 0.005000 0.998795 -v 0.000002 -0.005000 1.000000 -v 0.000002 0.005000 1.000000 -vt 0.985992 0.001342 -vt 0.986125 0.004167 -vt 0.999986 0.003515 -vt 0.972125 0.001989 -vt 0.972257 0.004817 -vt 0.958240 0.002631 -vt 0.958371 0.005463 -vt 0.944323 0.003267 -vt 0.944453 0.006107 -vt 0.930368 0.003899 -vt 0.930498 0.006747 -vt 0.916365 0.004525 -vt 0.916493 0.007384 -vt 0.902304 0.005145 -vt 0.902431 0.008017 -vt 0.888174 0.005758 -vt 0.888300 0.008645 -vt 0.873967 0.006365 -vt 0.874091 0.009268 -vt 0.859676 0.006964 -vt 0.859799 0.009885 -vt 0.845299 0.007556 -vt 0.845420 0.010494 -vt 0.830832 0.008137 -vt 0.830952 0.011094 -vt 0.816275 0.008707 -vt 0.816392 0.011683 -vt 0.801624 0.009266 -vt 0.801738 0.012260 -vt 0.786881 0.009812 -vt 0.786993 0.012825 -vt 0.772049 0.010344 -vt 0.772158 0.013376 -vt 0.757127 0.010861 -vt 0.757232 0.013911 -vt 0.742113 0.011363 -vt 0.742215 0.014431 -vt 0.727008 0.011848 -vt 0.727107 0.014935 -vt 0.711815 0.012315 -vt 0.711910 0.015420 -vt 0.696532 0.012762 -vt 0.696622 0.015885 -vt 0.681160 0.013188 -vt 0.681246 0.016329 -vt 0.665700 0.013592 -vt 0.665782 0.016750 -vt 0.650157 0.013972 -vt 0.650233 0.017147 -vt 0.634534 0.014327 -vt 0.634606 0.017518 -vt 0.618838 0.014658 -vt 0.618904 0.017864 -vt 0.603071 0.014964 -vt 0.603132 0.018183 -vt 0.587239 0.015245 -vt 0.587295 0.018477 -vt 0.571347 0.015502 -vt 0.571399 0.018746 -vt 0.555400 0.015735 -vt 0.555446 0.018990 -vt 0.539400 0.015942 -vt 0.539441 0.019207 -vt 0.523351 0.016123 -vt 0.523386 0.019398 -vt 0.507255 0.016277 -vt 0.507284 0.019561 -vt 0.491116 0.016401 -vt 0.491139 0.019694 -vt 0.474935 0.016494 -vt 0.474952 0.019796 -vt 0.458717 0.016555 -vt 0.458726 0.019863 -vt 0.442462 0.016580 -vt 0.442465 0.019896 -vt 0.426175 0.016569 -vt 0.426169 0.019891 -vt 0.409859 0.016518 -vt 0.409845 0.019846 -vt 0.393516 0.016426 -vt 0.393493 0.019759 -vt 0.377149 0.016288 -vt 0.377117 0.019626 -vt 0.360762 0.016103 -vt 0.360719 0.019445 -vt 0.344356 0.015870 -vt 0.344304 0.019215 -vt 0.327936 0.015588 -vt 0.327873 0.018935 -vt 0.311507 0.015254 -vt 0.311434 0.018603 -vt 0.295074 0.014870 -vt 0.294990 0.018219 -vt 0.278641 0.014434 -vt 0.278546 0.017782 -vt 0.262211 0.013944 -vt 0.262105 0.017292 -vt 0.245787 0.013401 -vt 0.245670 0.016747 -vt 0.229373 0.012804 -vt 0.229245 0.016148 -vt 0.212971 0.012153 -vt 0.212833 0.015495 -vt 0.196578 0.011449 -vt 0.196429 0.014789 -vt 0.180193 0.010695 -vt 0.180034 0.014033 -vt 0.163819 0.009891 -vt 0.163651 0.013227 -vt 0.147458 0.009041 -vt 0.147280 0.012375 -vt 0.131104 0.008148 -vt 0.130918 0.011481 -vt 0.114755 0.007216 -vt 0.114561 0.010547 -vt 0.098407 0.006248 -vt 0.098207 0.009579 -vt 0.082058 0.005250 -vt 0.081852 0.008581 -vt 0.065706 0.004228 -vt 0.065497 0.007560 -vt 0.049350 0.003188 -vt 0.049137 0.006521 -vt 0.032984 0.002136 -vt 0.032769 0.005471 -vt 0.016610 0.001077 -vt 0.016394 0.004413 -vt 0.000231 0.000014 -vt 0.000014 0.003351 -vt 0.999853 0.000691 -vn -0.024542 0.000000 0.999699 -vn -0.073565 0.000000 0.997290 -vn -0.122409 0.000000 0.992480 -vn -0.170962 0.000000 0.985278 -vn -0.219100 0.000000 0.975702 -vn -0.266712 0.000000 0.963776 -vn -0.313685 0.000000 0.949527 -vn -0.359896 0.000000 0.932992 -vn -0.405242 0.000000 0.914210 -vn -0.449609 0.000000 0.893226 -vn -0.492897 0.000000 0.870088 -vn -0.534998 0.000000 0.844853 -vn -0.575809 0.000000 0.817585 -vn -0.615230 0.000000 0.788347 -vn -0.653174 0.000000 0.757208 -vn -0.689540 0.000000 0.724247 -vn -0.724247 0.000000 0.689541 -vn -0.757208 0.000000 0.653174 -vn -0.788347 0.000000 0.615231 -vn -0.817585 0.000000 0.575808 -vn -0.844854 0.000000 0.534998 -vn -0.870087 0.000000 0.492898 -vn -0.893225 0.000000 0.449611 -vn -0.914210 0.000000 0.405242 -vn -0.932993 0.000000 0.359896 -vn -0.949528 0.000000 0.313681 -vn -0.963776 0.000000 0.266712 -vn -0.975702 0.000000 0.219102 -vn -0.985278 0.000000 0.170961 -vn -0.992480 0.000000 0.122410 -vn -0.997291 0.000000 0.073563 -vn -0.999699 0.000000 0.024541 -vn -0.999699 0.000000 -0.024541 -vn -0.997290 0.000000 -0.073566 -vn -0.992480 0.000000 -0.122410 -vn -0.985278 0.000000 -0.170962 -vn -0.975702 0.000000 -0.219102 -vn -0.963776 0.000000 -0.266714 -vn -0.949528 0.000000 -0.313682 -vn -0.932993 0.000000 -0.359895 -vn -0.914209 0.000000 -0.405242 -vn -0.893224 0.000000 -0.449611 -vn -0.870087 0.000000 -0.492898 -vn -0.844854 0.000000 -0.534998 -vn -0.817585 0.000000 -0.575808 -vn -0.788347 0.000000 -0.615231 -vn -0.757209 0.000000 -0.653172 -vn -0.724247 0.000000 -0.689541 -vn -0.689542 0.000000 -0.724246 -vn -0.653173 0.000000 -0.757208 -vn -0.615232 0.000000 -0.788346 -vn -0.575810 0.000000 -0.817584 -vn -0.534998 0.000000 -0.844853 -vn -0.492898 0.000000 -0.870087 -vn -0.449613 0.000000 -0.893224 -vn -0.405246 0.000000 -0.914208 -vn -0.359897 0.000000 -0.932992 -vn -0.313682 0.000000 -0.949528 -vn -0.266712 0.000000 -0.963776 -vn -0.219104 0.000000 -0.975701 -vn -0.170962 0.000000 -0.985278 -vn -0.122410 0.000000 -0.992480 -vn -0.073569 0.000000 -0.997290 -vn -0.024542 0.000000 -0.999699 -vn -0.170965 0.000000 0.985277 -vn -0.313681 0.000000 0.949528 -vn -0.359893 0.000000 0.932994 -vn -0.449612 0.000000 0.893224 -vn -0.492900 0.000000 0.870086 -vn -0.615233 0.000000 0.788346 -vn -0.653173 0.000000 0.757209 -vn -0.724248 0.000000 0.689539 -vn -0.817585 0.000000 0.575809 -vn -0.870088 0.000000 0.492897 -vn -0.893224 0.000000 0.449611 -vn -0.914210 0.000000 0.405241 -vn -0.932993 0.000000 0.359895 -vn -0.914209 0.000000 -0.405243 -vn -0.844853 0.000000 -0.534999 -vn -0.757208 0.000000 -0.653174 -vn -0.689541 0.000000 -0.724247 -vn -0.615233 0.000000 -0.788346 -vn -0.575807 0.000000 -0.817586 -vn -0.405239 0.000000 -0.914211 -vn -0.359893 0.000000 -0.932993 -vn -0.313686 0.000000 -0.949527 -vn -0.122413 0.000000 -0.992479 -s off -f 3/1/1 4/2/1 2/3/1 -f 5/4/2 6/5/2 4/2/2 -f 7/6/3 8/7/3 6/5/3 -f 9/8/4 10/9/4 8/7/4 -f 11/10/5 12/11/5 10/9/5 -f 13/12/6 14/13/6 12/11/6 -f 15/14/7 16/15/7 14/13/7 -f 17/16/8 18/17/8 16/15/8 -f 19/18/9 20/19/9 18/17/9 -f 21/20/10 22/21/10 20/19/10 -f 23/22/11 24/23/11 22/21/11 -f 25/24/12 26/25/12 24/23/12 -f 27/26/13 28/27/13 26/25/13 -f 29/28/14 30/29/14 28/27/14 -f 31/30/15 32/31/15 30/29/15 -f 33/32/16 34/33/16 32/31/16 -f 35/34/17 36/35/17 34/33/17 -f 37/36/18 38/37/18 36/35/18 -f 39/38/19 40/39/19 38/37/19 -f 41/40/20 42/41/20 40/39/20 -f 43/42/21 44/43/21 42/41/21 -f 45/44/22 46/45/22 44/43/22 -f 47/46/23 48/47/23 46/45/23 -f 49/48/24 50/49/24 48/47/24 -f 51/50/25 52/51/25 50/49/25 -f 53/52/26 54/53/26 52/51/26 -f 55/54/27 56/55/27 54/53/27 -f 57/56/28 58/57/28 56/55/28 -f 59/58/29 60/59/29 58/57/29 -f 61/60/30 62/61/30 60/59/30 -f 63/62/31 64/63/31 62/61/31 -f 65/64/32 66/65/32 64/63/32 -f 67/66/33 68/67/33 66/65/33 -f 69/68/34 70/69/34 68/67/34 -f 71/70/35 72/71/35 70/69/35 -f 73/72/36 74/73/36 72/71/36 -f 75/74/37 76/75/37 74/73/37 -f 77/76/38 78/77/38 76/75/38 -f 79/78/39 80/79/39 78/77/39 -f 81/80/40 82/81/40 80/79/40 -f 83/82/41 84/83/41 82/81/41 -f 85/84/42 86/85/42 84/83/42 -f 87/86/43 88/87/43 86/85/43 -f 89/88/44 90/89/44 88/87/44 -f 91/90/45 92/91/45 90/89/45 -f 93/92/46 94/93/46 92/91/46 -f 95/94/47 96/95/47 94/93/47 -f 97/96/48 98/97/48 96/95/48 -f 99/98/49 100/99/49 98/97/49 -f 101/100/50 102/101/50 100/99/50 -f 103/102/51 104/103/51 102/101/51 -f 105/104/52 106/105/52 104/103/52 -f 107/106/53 108/107/53 106/105/53 -f 109/108/54 110/109/54 108/107/54 -f 111/110/55 112/111/55 110/109/55 -f 113/112/56 114/113/56 112/111/56 -f 115/114/57 116/115/57 114/113/57 -f 117/116/58 118/117/58 116/115/58 -f 119/118/59 120/119/59 118/117/59 -f 121/120/60 122/121/60 120/119/60 -f 123/122/61 124/123/61 122/121/61 -f 125/124/62 126/125/62 124/123/62 -f 127/126/63 128/127/63 126/125/63 -f 129/128/64 130/129/64 128/127/64 -f 1/130/1 3/1/1 2/3/1 -f 3/1/2 5/4/2 4/2/2 -f 5/4/3 7/6/3 6/5/3 -f 7/6/65 9/8/65 8/7/65 -f 9/8/5 11/10/5 10/9/5 -f 11/10/6 13/12/6 12/11/6 -f 13/12/66 15/14/66 14/13/66 -f 15/14/67 17/16/67 16/15/67 -f 17/16/9 19/18/9 18/17/9 -f 19/18/68 21/20/68 20/19/68 -f 21/20/69 23/22/69 22/21/69 -f 23/22/12 25/24/12 24/23/12 -f 25/24/13 27/26/13 26/25/13 -f 27/26/70 29/28/70 28/27/70 -f 29/28/71 31/30/71 30/29/71 -f 31/30/16 33/32/16 32/31/16 -f 33/32/72 35/34/72 34/33/72 -f 35/34/18 37/36/18 36/35/18 -f 37/36/19 39/38/19 38/37/19 -f 39/38/73 41/40/73 40/39/73 -f 41/40/21 43/42/21 42/41/21 -f 43/42/74 45/44/74 44/43/74 -f 45/44/75 47/46/75 46/45/75 -f 47/46/76 49/48/76 48/47/76 -f 49/48/77 51/50/77 50/49/77 -f 51/50/26 53/52/26 52/51/26 -f 53/52/27 55/54/27 54/53/27 -f 55/54/28 57/56/28 56/55/28 -f 57/56/29 59/58/29 58/57/29 -f 59/58/30 61/60/30 60/59/30 -f 61/60/31 63/62/31 62/61/31 -f 63/62/32 65/64/32 64/63/32 -f 65/64/33 67/66/33 66/65/33 -f 67/66/34 69/68/34 68/67/34 -f 69/68/35 71/70/35 70/69/35 -f 71/70/36 73/72/36 72/71/36 -f 73/72/37 75/74/37 74/73/37 -f 75/74/38 77/76/38 76/75/38 -f 77/76/39 79/78/39 78/77/39 -f 79/78/40 81/80/40 80/79/40 -f 81/80/78 83/82/78 82/81/78 -f 83/82/42 85/84/42 84/83/42 -f 85/84/43 87/86/43 86/85/43 -f 87/86/79 89/88/79 88/87/79 -f 89/88/45 91/90/45 90/89/45 -f 91/90/46 93/92/46 92/91/46 -f 93/92/80 95/94/80 94/93/80 -f 95/94/48 97/96/48 96/95/48 -f 97/96/81 99/98/81 98/97/81 -f 99/98/50 101/100/50 100/99/50 -f 101/100/82 103/102/82 102/101/82 -f 103/102/83 105/104/83 104/103/83 -f 105/104/53 107/106/53 106/105/53 -f 107/106/54 109/108/54 108/107/54 -f 109/108/55 111/110/55 110/109/55 -f 111/110/84 113/112/84 112/111/84 -f 113/112/85 115/114/85 114/113/85 -f 115/114/86 117/116/86 116/115/86 -f 117/116/59 119/118/59 118/117/59 -f 119/118/60 121/120/60 120/119/60 -f 121/120/61 123/122/61 122/121/61 -f 123/122/87 125/124/87 124/123/87 -f 125/124/63 127/126/63 126/125/63 -f 127/126/64 129/128/64 128/127/64 diff --git a/examples/qt3d/audio-visualizer-qml/music/tiltshifted_lost_neon_sun.mp3 b/examples/qt3d/audio-visualizer-qml/music/tiltshifted_lost_neon_sun.mp3 deleted file mode 100644 index a9a3850f3..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/music/tiltshifted_lost_neon_sun.mp3 and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/music/visualization.raw b/examples/qt3d/audio-visualizer-qml/music/visualization.raw deleted file mode 100644 index 0b2d7c444..000000000 Binary files a/examples/qt3d/audio-visualizer-qml/music/visualization.raw and /dev/null differ diff --git a/examples/qt3d/audio-visualizer-qml/touchsettings.cpp b/examples/qt3d/audio-visualizer-qml/touchsettings.cpp deleted file mode 100644 index 83fce6392..000000000 --- a/examples/qt3d/audio-visualizer-qml/touchsettings.cpp +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -#include "touchsettings.h" - -#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) -#define DEVICE QInputDevice -#include -#else -#define DEVICE QTouchDevice -#include -#endif - -#include - -TouchSettings::TouchSettings(QObject *parent) - : QObject(parent) -{ -} - -bool TouchSettings::isHoverEnabled() const -{ -#if defined(Q_OS_IOS) || defined(Q_OS_ANDROID) || defined(Q_OS_QNX) || defined(Q_OS_WINRT) - return false; -#else - const auto devices = DEVICE::devices(); - bool isTouch = false; - for (const DEVICE *dev : devices) - if (dev->type() == DEVICE::DeviceType::TouchScreen) { - isTouch = true; - break; - } - bool isMobile = false; - if (qEnvironmentVariableIsSet("QT_QUICK_CONTROLS_MOBILE")) { - isMobile = true; - } - return !isTouch && !isMobile; -#endif -} diff --git a/examples/qt3d/audio-visualizer-qml/touchsettings.h b/examples/qt3d/audio-visualizer-qml/touchsettings.h deleted file mode 100644 index 9320e90c4..000000000 --- a/examples/qt3d/audio-visualizer-qml/touchsettings.h +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright (C) 2017 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause - -#ifndef TOUCHSETTINGS_H -#define TOUCHSETTINGS_H - -#include - -class TouchSettings : public QObject -{ - Q_OBJECT -public: - explicit TouchSettings(QObject *parent = 0); - - Q_INVOKABLE bool isHoverEnabled() const; - -}; - -#endif // TOUCHSETTINGS_H -- cgit v1.2.3