summaryrefslogtreecommitdiffstats
path: root/src/core/transforms
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.15' into devMike Krus2020-04-271-2/+2
|\ | | | | | | Change-Id: Id669d5c1aab29965eac0dabd1cb497e908dac23e
| * Fix compilation on Windows with -qt3d-simd avx2Paul Lemire2020-04-201-2/+2
| | | | | | | | | | | | | | | | | | | | | | Q_3DCORE_PRIVATE_EXPORT for operator* were removed by commit: fa6799f63f3211300705b814b97716ca689d4bfa for Vector3D_SSE and Matrix4x4_SSE. Unfortunately they weren't removed for Matrix4x4_AVX2 which lead to different linkage compile errors. Change-Id: I854fb0cb4409aea1d130e935091533d4e72d6d6e Reviewed-by: Mike Krus <mike.krus@kdab.com>
* | Track dirty state on front end nodesMike Krus2020-04-072-0/+11
| | | | | | | | | | | | | | Nothing clears the state yet, will be up to the core aspect to do that. Change-Id: Ia3a5297a4b837b1d67545bd29ddce56666c520f3 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | Remove deprecated classes and functionsPaul Lemire2020-02-1114-122/+14
|/ | | | | | | Mostly old messaging API Change-Id: I17eb2206b2ede56d2f7d36375d5e711d6149019f Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Remove unneeded export of inline functionsFriedemann Kleint2020-02-072-5/+5
| | | | | | | | | Fix MinGW-warings src/core/transforms/matrix4x4_sse_p.h:485:50: warning: inline function 'Vector3D Qt3DCore::operator*(const Qt3DCore::Matrix4x4_SSE&, const Vector3D&)' declared as dllimport: attribute ignored [-Wattributes] Q_3DCORE_PRIVATE_EXPORT Q_ALWAYS_INLINE Vector3D operator*(const Matrix4x4_SSE &matrix, const Vector3D &vector) Change-Id: Ib8b39c613ce05b6dc3848c1251a88eea53903212 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Make the OpenGL renderer a pluginPaul Lemire2020-02-052-0/+2
| | | | | | | | By default the QRenderAspect will try to load this plugin Change-Id: Ie55e207fb8e6d0b64f717bbb99699eb669eaa3f2 Task-number: QTBUG-61151 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Fix usages of text stream operatorsAlexandru Croitor2019-12-062-10/+10
| | | | | | Change-Id: I8f3fe9475749f10f33c8eb750befa8845ccc37d6 (cherry picked from commit 58db7d01e0d424fdf46baa70e2e41b8009429c78) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix skeleton loadingMike Krus2019-10-252-16/+23
| | | | | | | | Set the nodes created on the backend properly (assigning parent) so that the backend nodes get created before the second round of updates. Change-Id: Ia8ac9aacfc6bdb8938d07dbf714d471b5ddc4999 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Revert removal of more sceneChanged methodsMike Krus2019-10-242-0/+9
| | | | | | | Removal breaks BC Change-Id: I8c324253c3a39c8fd74bf4cc14462f76cd2e4f5e Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Restore sceneChangeEvent overload that were removedPaul Lemire2019-10-222-0/+2
| | | | | | | | Not BIC compatible so they must stay until Qt6. Added TODO above them to make it easier to track for Qt6. Change-Id: Ia1adba25be5d55d3fa836727877c7c1f7346b668 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Remove remaining messaging code in QSkeletonLoaderMike Krus2019-10-221-12/+0
| | | | | | | And matching unit tests Change-Id: Iff0b13b2ad9ff07d08c767f4b20de2a1685a5570 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Remove old code from animation classes & update testsMike Krus2019-10-212-12/+0
| | | | | Change-Id: Ic91a4f168172d6f34d858488e6fc170e8ed875f9 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix Coverity warningsMike Krus2019-10-212-0/+3
| | | | | Change-Id: I00c875b48d838170fddf0b92f0ac5592828c6f0f Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Clean QJoint message handlingMike Krus2019-10-111-3/+2
| | | | | Change-Id: Ib09024017a2d213e50b3acc89d7c411728eb1869 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update LoadSkeletonJob to use direct syncMike Krus2019-10-081-0/+1
| | | | | Change-Id: I5622f9784628b7217f6e37c700ac314b7264f439 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update animation evaluation jobs to use direct syncMike Krus2019-10-082-0/+11
| | | | | | | | | | | | | | Animation data is now stored in the job which propagates them to the frontend at the end of the frame. Animated properties are passed using Qt's property system. Animated poses are passed via the frontend skeleton node. Syncing on new frame will take care of propagating both for use in other aspects. Callbacks are called by the job directly or stored and invoked on the main thread depending on the callback setting. Change-Id: I78675715799300bc1b27f854f1a445c00a2ac734 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix missing exportsMike Krus2019-10-026-6/+6
| | | | | Change-Id: Ibf24099223bd35948f50a492e0d754f6f680a3db Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Clean up includesMike Krus2019-10-011-3/+0
| | | | | | | | | Remove include statements for classes that are no longer used. Makes it easier to find remaining use cases that need addressed before complete removal in Qt 6. Change-Id: I60529ba1929ad64b162d3847d5df47cde2a60dad Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* QTransform: move setWorldMatrix to private classPaul Lemire2019-09-193-7/+9
| | | | | | Change-Id: Ifc8b172414e01cebcaf42c30773376c43aaae9a9 Task-number: QTBUG-77859 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Update QJoint to use direct syncMike Krus2019-09-181-10/+4
| | | | | Change-Id: I2b86f182a61c18cb6608f2f89938ab342160c924 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-09-112-16/+12
|\ | | | | | | Change-Id: I4e73060c1941773efcc568f010f5b073ebb10d4a
| * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-08-242-16/+12
| |\ | | | | | | | | | Change-Id: I7d7274866129a3c8a3ed3788680a46368120d20d
| | * Matrix_SSE/Matrix_AVX2: fix mapVectorPaul Lemire2019-08-202-16/+12
| | | | | | | | | | | | | | | | | | Change-Id: I4584d2c879a72eccbaf273d0e84b3b6f6bb55295 Task-number: QTBUG-77675 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* | | QTransform: add worldMatrix propertyPaul Lemire2019-08-133-1/+72
|/ / | | | | | | | | | | | | | | | | | | | | Will make it more convenient to retrieve the world transform of a given QEntity as well as monitor it for changes without having to traverse the parent hierarchy of QEntity/QTransform [ChangeLog] Add worldMatrix property on QTransform Change-Id: Ie9ffb70c03b365850ed08693df2746701ca9a1fb Reviewed-by: Mike Krus <mike.krus@kdab.com>
* / Switch export macros to standard formKai Koehne2019-04-0210-22/+22
|/ | | | | | | | | | | | Qt expects the export macros to have Q_ prefixes, otherwise the symbol versioning script won't find them and mark them. Also remove non-exising QT3DLOGIC_PRIVATE_EXPORT macro from src/doc/qt3d.qdocconf Task-number: QTBUG-74752 Change-Id: I71b9e85ff09c002fb283824aa51a5a8f50e937f4 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix unfinished commentThiago Macieira2018-12-121-0/+1
| | | | | | | | Found by ICC. Change-Id: I4ac1156702324f0fb814fffd156f815f33110f71 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Doc: Add doc to undocumented methodsNico Vertriest2018-11-012-1/+17
| | | | | | | | | | | | | - qcomponent.cpp - qbackendnode.cpp - qjoint.cpp - qskeletonloader.cpp - qframeaction.cpp - qscene2d.h - qrenderaspect.cpp Change-Id: I25881dee19d2d01f948bfaf4a156a97f6caaea73 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Doc: Add missing dots (qt3d)Paul Wicking2018-06-196-12/+12
| | | | | | Task-number: QTBUG-68933 Change-Id: I4226b8b9d70548b6921948c5ea47520f40f5df98 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Fix SIMD related warningsPaul Lemire2018-02-281-2/+4
| | | | | Change-Id: Ia7d08551de0b10e3e859da5301ea8e2be501c722 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* simd: declare AVX2 friends only if __AVX2__ definedPaul Lemire2018-02-283-13/+20
| | | | | Change-Id: I8fd88461874367bcaa9f4b27a9b4fc660cd2a030 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Doc: Fix documentation warnings for Qt 3D CoreTopi Reinio2018-02-161-1/+1
| | | | | | | | | | | | This change fixes multiple QDoc warnings for Qt 3D Core that are related to how Clang parses the source code and the \fn QDoc commands. We still have a number of 'No documentation for ...' warnings left - those are not addressed in this change. Change-Id: Ia6394f453d7bd959bc4d4cc9347ac0039b80f661 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Merge remote-tracking branch 'origin/5.10' into 5.11Sean Harmer2018-02-153-0/+36
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/animation/doc/src/qt3danimation-module.qdoc src/render/backend/abstractrenderer_p.h src/render/backend/buffervisitor_p.h src/render/backend/renderer.cpp src/render/backend/renderer_p.h src/render/backend/triangleboundingvolume_p.h src/render/backend/trianglesextractor_p.h src/render/frontend/sphere_p.h src/render/jobs/calcboundingvolumejob.cpp src/render/jobs/job_common_p.h src/render/jobs/pickboundingvolumejob.cpp src/render/jobs/pickboundingvolumejob_p.h src/render/jobs/pickboundingvolumeutils.cpp src/render/jobs/renderviewjobutils_p.h tests/auto/render/boundingsphere/tst_boundingsphere.cpp tests/auto/render/commons/testrenderer.h tests/auto/render/raycasting/tst_raycasting.cpp tests/auto/render/render.pro tests/auto/render/renderer/tst_renderer.cpp Change-Id: I76633bc5a5a065e5f9ea62cc16563377e5c693a3
| * Render: Use SIMD Vectors and Matrices in the backendPaul Lemire2018-02-023-0/+36
| | | | | | | | | | Change-Id: I19b3b2f8fcb06eb2bc600ebe370465dd15a8eabc Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | Merge branch '5.10' into devSean Harmer2018-01-263-4/+14
|\| | | | | | | Change-Id: I4728b29c349a16867951a781c9417054c798e04a
| * SIMD: Only include SSE classes if options activatedPaul Lemire2018-01-253-4/+14
| | | | | | | | | | | | | | | | | | Relying on the SSE2 or AVX2 defines results in some SSE/AVX classes being included even though the options were disabled, resulting in compile failures. Change-Id: Ie1e3ce2f093eeb3f749ef215835fa0846fbb5019 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | QTransform: add fromAxes and rotateFromAxes helperPaul Lemire2018-01-252-0/+23
| | | | | | | | | | | | | | | | | | | | Make it a lot easier to create a QQuaternion or a Rotation matrix for 3 axes. This will greatly simplify implementing custom camera nodes from Transform and CameraLens. Change-Id: Ifed9e3c7442d451ffa4346223afecc0eafff0ed5 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Mike Krus <mike.krus@kdab.com>
* | Merge remote-tracking branch 'origin/5.10' into devAndy Nichols2017-11-132-21/+34
|\| | | | | | | Change-Id: I2d373d538df3a65ac2d41238e5c6a214a151be68
| * Decompose a new quaternion rotation into euler anglesSean Harmer2017-10-062-21/+34
| | | | | | | | | | | | | | Same as in QTransform. Change-Id: Ia1dca19c8faf996629ecbf8832e5625e7b22532c Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-10-051-0/+1
|\| | | | | | | | | | | | | Conflicts: src/animation/backend/channelmapper_p.h Change-Id: I4e0f59c6648925ba45d30ccc2405524a9e901a0e
| * Update the local poses of the skeleton in the animation aspectSean Harmer2017-10-031-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At present it is still needlessly, and incorrectly, updating the transforms of joints for which we have no animation data by using a default value of 0 for each component. This causes the joints to be scaled to 0 which is not particularly useful. We should only update joints for which we have valid animation data and leave the other joints alone. For a skeleton this will be OK as we have the initial set of local poses available. For regular QNode properties, the animator/mapper will need to take a snapshot of the current property value when the animation is started so that we can fill in the missing values when generating property changes. This should also be fixed on the 5.9 branch. Change-Id: Ib8f28c55cdfbca3f335777028f72250641092fc9 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | Replace Q_DECL_OVERRIDE with overrideKevin Funk2017-09-251-1/+1
|/ | | | | Change-Id: I92c955068e233c50043ad7d06a32300dd386c24d Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Send joint names and local poses from render to animation aspectSean Harmer2017-08-301-0/+16
| | | | | | | | | This will allow the animation aspect to easily update the local poses of all joints in a skeleton without needing to be able to address any frontend QJoint objects. Change-Id: Id2137f2533702387dc68296aba1dd8627b0599d6 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Add name property to QJointSean Harmer2017-08-303-0/+23
| | | | | | | And set it from the backend when creating frontend joints. Change-Id: I26d37c7f516944eb353af38716aab4c55bd2f79f Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Add euler rotation angle convenience properties to QJointSean Harmer2017-08-163-0/+113
| | | | | | | As we did for QTransform. These are frontend only properties. Change-Id: Ic2fb1080ff68e26437c7e35632bdfcc00e51c017 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Create SkeletonData from Joint backend nodesSean Harmer2017-08-161-0/+1
| | | | | | | | | | | | | | This can be done either by using a QSkeleton on the frontend or with a QSkeletonLoader that has the createJointsEnabled property set to true. In the latter case, the loader creates the joint node hierarchy on the backend then moves them to the main thread in a similar way to QGeometryRenderer handles Geoemtry. Once the joint hierarchy is set on the frontend QSkeletonLoader, it notifies the backend and from there it follows the same code path as for QSkeleton. Change-Id: I5f673e154bb3a3e677b80b8ee984f4168403c288 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update skinned mesh example to expose joints of objectSean Harmer2017-08-166-3/+190
| | | | | | | | | | | | | To do this we add a helper Sqt struct that wraps up an affine transformation as a scale vector, rotation quaternion and a translation vector. This is the format in which the animation aspect will animate the joints later so it's easier to keep the transforms split like this. It's also less data to move around compared with a 4x4 matrix (10 vs 16 floats, 12 including the padding). Change-Id: Iaa30b5ef5d1635cc208ead918827140cf2765908 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Matrix4x4: simd (AVX2 and SSE) matrix classesPaul Lemire2017-08-119-10/+1400
| | | | | Change-Id: I8a4d8542a12a9ec6631f76515c0da41cd1c679fe Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add inverseBindMatrix property to QJointSean Harmer2017-08-103-0/+43
| | | | | | | Needed to compute skinning palette of matrices. Change-Id: Ifec41c2bb18855bbb2c332cf80d37642d34f75cf Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Change scale property of QJoint to QVector3DSean Harmer2017-08-103-11/+11
| | | | | | | Seems to be the norm for joints. Change-Id: I98d786b64153b09e2cd06e9d525f6c80f6372316 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Add Vector3D simd classPaul Lemire2017-08-105-8/+544
| | | | | Change-Id: I9a454a3b3be3ad1878eaf09cf2ff77aa2bfbe208 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>