summaryrefslogtreecommitdiffstats
path: root/src/animation/backend
Commit message (Collapse)AuthorAgeFilesLines
* Enable compiling non-QML API against Qt 5.15Mike Krus2021-01-051-1/+1
| | | | | | | | | | | | Built with QtQuick disabled. - C++17 required - minor issues with QList vs QVector - QMutexLocker templated vs not - moc forward declaration handling Change-Id: I5540625e74e2c009e528f56203e4b88be8d54599 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Restore use of QVector in private APIMike Krus2021-01-0521-125/+123
| | | | | | | | Facilitates building against Qt 5.15. Will migrate to std::vector over time. Change-Id: I5db14c9ea95b38e4b2d596d7397fef76f6baf118 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix deprecated API usage and compile warningsMike Krus2020-11-208-38/+39
| | | | | | | | | - QVariant::Type deprecated, use QMetaType related APIs - QNodeId not used as reference in for loops (nop but really noisy) - some unused code Change-Id: I291219207fcd1ad0bf89533b4e2bb5fa47a353bb Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Replace old Q_DECL statements with modern C++Allan Sandfeld Jensen2020-11-021-8/+8
| | | | | | | | Since we have long depended on C++11 now, all of these can go. Change-Id: I8808af2cd5ce192864c636b521dadd7de189563b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Avoid multiple animation updatesMike Krus2020-10-161-3/+6
| | | | | | | | | Check that the handle is not already in the lists. Avoids doing the same updates several times in the Pick-to: 5.15 Change-Id: I385b150de23a2ae7f2274c7d7350a065bb0c34f5 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix animation not runningMike Krus2020-09-253-21/+21
| | | | | | | | Previous fix for compile issue forgot to account for the fact that the data changes after being registered with the class. Change-Id: Ice5238221f190f758ec3f25d883c56877c185e1c Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* evaluateClipAtLocalTime: prevent negative indices for keyframes lookupPaul Lemire2020-09-181-1/+1
| | | | | | | Pick-to: 5.15 Pick-to: 5.12 Change-Id: I811c1a7334674d670f42eb46195e2e0e23b690f3 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Fix build with latest QtBase and QtDeclarativeMike Krus2020-09-071-1/+1
| | | | | | Task-number: QTBUG-86410 Change-Id: I26427d65de72c86f952b076259979f90eaef87f4 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Fix compilation with newer qtbaseFabian Kosmale2020-08-251-0/+1
| | | | | Change-Id: Iaba2780c2ac28181cce15ae350fadd755a51999f Reviewed-by: Daniel Smith <Daniel.Smith@qt.io>
* Fix build to change in typeof QList::size()Mike Krus2020-07-171-2/+2
| | | | | Change-Id: Ib480a8eef157102df8f89a75983cd4d8d46a9388 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Use QList instead of QVector in implementation and docsJarek Kobus2020-07-0931-187/+180
| | | | | | | | | Fix some const correctness. Use list-initialization. Task-number: QTBUG-84469 Change-Id: I9c56742581f48f89a3b02e4121fae414117c7a25 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* QAspectJob: switch to using std::vectorPaul Lemire2020-07-022-3/+3
| | | | | Change-Id: I1314bd4d37ad17442ebd6287f571e41bc5d25490 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Animation Handler: assign iterator on erasePaul Lemire2020-06-301-3/+3
| | | | | | | Change-Id: Ia65be6befec3aa07080650ad82c59053b6d3670b Pick-to: 5.15 Pick-to: 5.12 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Add ; to Q_UNUSEDLars Schmertmann2020-06-241-1/+1
| | | | | | | | This is required to remove the ; from the macro with Qt 6. Task-number: QTBUG-82978 Change-Id: I2e126d0be8efa0aa89c4a91a681b549f38c8cec4 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Merge remote-tracking branch 'origin/5.15' into devMike Krus2020-04-2710-35/+40
|\ | | | | | | Change-Id: Id669d5c1aab29965eac0dabd1cb497e908dac23e
| * Animations: fix race condition on running clip animators vectorPaul Lemire2020-04-201-15/+10
| | | | | | | | | | | | | | | | | | | | | | Was caused by incorrect dependencies on the jobs. Introduced a clearDependencies on QAspectJobPrivate to clear all dependencies as removeDepencies(emptyVector) only removes null dependencies. Change-Id: I8119a9edaf841db6c5ab2a971dc5640da2192cba Reviewed-by: Mike Krus <mike.krus@kdab.com>
| * Animation: remove unused m_drityChannelMapper vectorPaul Lemire2020-04-142-4/+0
| | | | | | | | | | | | | | Avoids wasting time adding to it given it's not used. Change-Id: I7a3f30a7d56cb34bb60c79661aee0061c0dcb577 Reviewed-by: Mike Krus <mike.krus@kdab.com>
| * Animations: prevent FindRunningClipAnimatorJob from running every framePaul Lemire2020-04-146-8/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The job it does takes a fair amount of time and only needs to run occasionally. We would reset the normalized time on the backend node every frame which then lead to a dirty set being set when synching again with the frontend. This might not have happened every frame prior to the synching refactorings. However currently, after every animation step, the dirty set would be reset and the job scheduled to run again even though nothing had really changed. This patch fixes that by setting the normalized time on the backend node prior to the synching with the frontend. That way, when we sync with the frontend the values are either identical when playing the animation unless the user really has changed the normalizedTime value. Change-Id: Iade4e7bfd47d34ef083d8e3398180a71630c0c81 Reviewed-by: Mike Krus <mike.krus@kdab.com>
| * Properly stop running animations when using a negative playratePaul Lemire2020-03-303-8/+14
| | | | | | | | | | | | | | | | When reaching a normalized time of 0 they would otherwise continue to run Change-Id: Idaea755d3a12f9c9da9c25732c2221e9b3f9f4c7 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* | Add QBackendNode::syncFromFrontEnd to public APIMike Krus2020-02-271-1/+1
| | | | | | | | | | | | | | | | | | Removes need to per aspect overrides of QAbstractAspectPrivate::syncDirtyFrontEndNode which was required in Qt5 to preserve BC. Change-Id: Ib3b05af1c3ded1c985d35e4dec0fe203cdc907cb Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | Geometry refactoringMike Krus2020-02-273-24/+24
| | | | | | | | | | | | | | Move QBuffer, QAttribute, QGeometry to Qt3DCore. Change-Id: I59dfd091eefadcada93350b3aba955f40b304385 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* | Merge remote-tracking branch 5.15 into devMike Krus2020-02-171-4/+12
|\| | | | | | | Change-Id: I2777f6a40b9029ef5569a84e04f9e18a914504e7
| * Animations: handle colors as vec3 or vec4Paul Lemire2020-02-121-4/+12
| | | | | | | | | | Change-Id: If450816fadce4adad4881938ecaea9c4000afe16 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* | Remove deprecated classes and functionsPaul Lemire2020-02-117-16/+7
|/ | | | | | | Mostly old messaging API Change-Id: I17eb2206b2ede56d2f7d36375d5e711d6149019f Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Remove QtGui module path from OpenGL related pathsMike Krus2020-02-061-1/+1
| | | | | | | | Many are moving to opengl module in qt6, will make merging easier. Change-Id: I0ad08510e6999a5d887d9197fe2cb0dc21919fb9 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix usages of text stream operatorsAlexandru Croitor2019-12-064-17/+17
| | | | | | Change-Id: I8f3fe9475749f10f33c8eb750befa8845ccc37d6 (cherry picked from commit 58db7d01e0d424fdf46baa70e2e41b8009429c78) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Revert "Update jobs to remove post FF changes"Mike Krus2019-12-034-2/+7
| | | | | | | d521b994450f0a4febbd789ba66701ba24fdbe22 Change-Id: Ibe6d608e8400e69b50775c0eb156e74e4e90b25c Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Avoid initializing QFlags with 0 or nullptrFriedemann Kleint2019-11-251-2/+1
| | | | | | | It is being deprecated. Change-Id: Idb6e794be1a26a3ca7c1d19ac1f47e4a0125f11b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Accept CBOR as optional format in gltf dataUlf Hermann2019-10-291-6/+4
| | | | | Change-Id: I8e64f061147af10a0d017238664c483724047059 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Update jobs to remove post FF changesMike Krus2019-10-224-7/+2
| | | | | | | Made the d_ptr private again. Change-Id: Ia5ba23b03cd22290d5c922e9a1c657a67ff98977 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix Coverity warningsMike Krus2019-10-218-9/+11
| | | | | Change-Id: I00c875b48d838170fddf0b92f0ac5592828c6f0f Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Clean up old property update codeMike Krus2019-10-201-1/+0
| | | | | | | Remove useless includes, clear up commented out or unused code Change-Id: Id3382b16108d79f1e2522d43463c8d70aef8fcb2 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Update LoadSkeletonJob to use direct syncMike Krus2019-10-082-22/+12
| | | | | Change-Id: I5622f9784628b7217f6e37c700ac314b7264f439 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update animation evaluation jobs to use direct syncMike Krus2019-10-0815-140/+286
| | | | | | | | | | | | | | 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>
* Update LoadAnimationClipJob to use direct syncMike Krus2019-10-083-16/+45
| | | | | Change-Id: I41f8de8776c40cf9ed4f08c33bd480a719aa1c82 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Fix backend property updatesMike Krus2019-10-031-1/+1
| | | | | Change-Id: I8f8967185d3db8220808135a7e81bdae411186fc Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Clean up includesMike Krus2019-10-016-11/+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>
* Update QChannelMapper to use direct syncMike Krus2019-09-232-34/+16
| | | | | Change-Id: I066b6742cc272155f55322e3aaf73e28980341d0 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update mapping classes to use direct syncMike Krus2019-09-232-65/+35
| | | | | | | QChannelMapping, QSkeletonMapping and QCallbackMapping updated. Change-Id: I10b78d86856f6ad01fbb313fdcbe9f87f6d926ac Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QLerpClipBlend to use direct syncMike Krus2019-09-202-26/+12
| | | | | Change-Id: I91ce052b27eb822e79b80fa11ccd3d4b9f76ded4 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QClipBlendValue to use direct syncMike Krus2019-09-202-17/+7
| | | | | Change-Id: I14add80f1519ec3047f7e5e925136230dec6874b Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QAdditiveClipBlend to use direct syncMike Krus2019-09-202-25/+10
| | | | | Change-Id: If1349879cd05ce8616152ef4f5395c76b961ab74 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QAbstractSkeleton to use direct syncMike Krus2019-09-202-10/+1
| | | | | | | | Nothing to sync and keep old message based method for backend to backend communication Change-Id: I494f1e8ba62aa772e87878959754a3e6a67681a1 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QBlendedClipAnimator to use direct syncMike Krus2019-09-202-38/+29
| | | | | Change-Id: I6b00f22196d29b5219e27e5084c379b69b68c6e5 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QClipAnimator to use direct syncMike Krus2019-09-202-38/+27
| | | | | Change-Id: I33cd39df0762a54c7d1beb74b57fd804bb2ae3e9 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QClock to use direct syncMike Krus2019-09-202-22/+8
| | | | | Change-Id: I37183c67b3f6e8b08a1b050693879aa811cf48c9 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QAnimationClip (and Loader) to use direct syncMike Krus2019-09-202-40/+24
| | | | | Change-Id: I22713a75f59075b1fe997405ad770f3a95ec37ac Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Enable syncing on animation aspectMike Krus2019-09-202-0/+11
| | | | | Change-Id: I4333cb98d4339fa9dc02ebb27231aad748fdb3c2 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QTransform to use direct syncMike Krus2019-09-181-0/+3
| | | | | Change-Id: Ib70df957a8eb40d032aeb314fab01e7479e7150a Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Animations: don't assert if mapper is not setPaul Lemire2019-08-261-1/+2
| | | | | | | | | We might provide it later, current approach forces it to be set at construction time which doesn't work if you use delayed loading of meshes and mappers. Change-Id: I8ee95d4751cb951d3a99c2fb80b1d5ba77905a2d Reviewed-by: Mike Krus <mike.krus@kdab.com>