summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| * Add manual test for dynamic slide resource loadingAntti Määttä2019-03-1215-1/+491
| | | | | | | | | | Change-Id: If546d18a2dc0bc2f60c5f703b108c081ef8e89b0 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Implement delayed image loading and slide resource listMäättä Antti2019-03-1213-395/+1030
| | | | | | | | | | | | | | | | Task-number: QT3DS-2664 Change-Id: I5310329fbf6e4e07cade28ae68161081ddf77f3c Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
| * Load subpresentations asynchronouslyAntti Määttä2019-03-1210-65/+337
| | | | | | | | | | | | | | | | Task-numer: QT3DS-2664 Change-Id: I612d81f08681eec1a396c1f48b75ca02cc12e8bf Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* | Merge branch '2.3' into masterMiikka Heikkinen2019-03-11129-2695/+2036
|\| | | | | | | Change-Id: I3920a6362edb4442a4f77f2efec3329f8dd6b92a
| * Stabilize color values from the animatorChristian Strømme2019-03-111-1/+7
| | | | | | | | | | | | | | | | Ensure that color values are strictly in the 0-1 range Change-Id: I336c990438937a91ee89edac44ccf7ee075a8af3 Reviewed-by: Janne Kangas <janne.kangas@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Fix crash when adding a layerMiikka Heikkinen2019-03-111-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | stereoModeParam needs to be parented to the layerSceneRootEntity like other parameters or runtime will crash when the compositor layer chain is rebuilt. If it is not explicitly parented, the renderpass will own it and delete it when it gets destroyed during rebuild. Task-number: QT3DS-3092 Change-Id: Ide3af92ec5af5eab3413b9ab8833a2138865410d Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Kaj Grönholm <kaj.gronholm@qt.io>
| * Fix datainput metadata APIJanne Kangas2019-03-0819-133/+216
| | | | | | | | | | | | | | | | | | | | | | Change metadata to a full key-value hash table. Change getter APIs to match customer requirements. Parent created Q3DSDataInput objects to Q3DSEngine and do lazy initialization when needed. Change UIA parsing to match Editor-side changes. Add QML-side methods to access metadata. Change-Id: Ife6a6adf498f6daa3f6fa383fcfe837e4d36741c Task-id: QT3DS-3046 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Fix data input for changing slides in nested componentsChristian Strømme2019-03-071-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | Removed useless check that tested if the component was on the master or current slide, as that's not necessarily the case when you have nested components. Fixes: QT3DS-3033 Change-Id: I0af07a36ee7db62c355434ecdf8ee351a1fef505 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit bad87a705817355996c8265f5424beae39948e86) Reviewed-by: Christian Strømme <christian.stromme@qt.io>
| * Do not cache datainput min/max rangesJanne Kangas2019-03-076-48/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Always query datainput range min/max values from the engine level instead of caching the latest value at Q3DSDataInput level. This is to prevent issues with several Q3DSDataInput objects referring to same datainput entry getting out of sync. For QML, change signal is emitted only for local changes, not for changes through other datainput instances. Task-id: QT3DS-3001 Change-Id: I6e17aeca9ddc6ef59a11fb08ea8e33ccf283b743 Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> (cherry picked from commit f05671f64981374fb3d4e598db19ce2a3f142f75) Reviewed-by: Christian Strømme <christian.stromme@qt.io>
| * Dragon: Fix dirty markingKaj Grönholm2019-03-071-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When "markDirty(DirtyTreeInfo{})" was called to mark rendering tree dirty and then some place called plain "markDirty()", the latter replaced former and tree didn't get updated. Instead only add default dirty entry if it doesn't already exist. This fixes stereoscopic mode switching with dragon, but also some other cases where render tree changes. Task-number: QT3DS-2933 Change-Id: I8494fa03059b214e8fe703681f911aa438f95fcf Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Antti Määttä <antti.maatta@qt.io> Reviewed-by: Christian Strømme <christian.stromme@qt.io>
| * Fix crash in updateSizesAntti Määttä2019-03-071-1/+1
| | | | | | | | | | | | | | | | | | Add nullptr check to light gatherer since the attached might not have been created yet. Task-number: QT3DS-3127 Change-Id: Ideaad988ac03b829c8876def1ee3076c560034b9 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Defer calling updateGlobals() when changing visibility on a layersChristian Strømme2019-03-041-1/+7
| | | | | | | | | | | | | | | | | | | | We need to know the state of the camera before calling updateGlobals() on a layer, as all other nodes will have the effective visibility update accordingly. Fixes: QT3DS-3080 Change-Id: Ie1b5e77a03d07c66d80c3a30b391452c41de70dc Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Update MetaData.xmlv2.3.0-beta2Miikka Heikkinen2019-03-013-79/+113
| | | | | | | | | | | | | | | | | | Materials no longer have name property, the default value is obtained from MaterialBase. Changed the property parsing logic accordingly. Change-Id: I40653eeefcbeb1c4e293b75b328ebc4a66f2b2de Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Antti Määttä <antti.maatta@qt.io>
| * Do not double the shadow draw distanceTomi Korpipää2019-03-011-2/+2
| | | | | | | | | | | | | | | | | | | | Keep the draw distance for the directional light shadow within camera clip distance instead of doubling it. Task-number: QT3DS-3118 Change-Id: Id7e7b5ffab9856729338ceb72ea366b7c04697e4 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Fix q3dsviewer with distance field fontsKaj Grönholm2019-03-011-1/+0
| | | | | | | | | | | | | | | | | | Don't delete m_glyphCacheManager as that node is owned by Qt3D and will get deleted automatically when parent m_rootEntity is deleted. Task-number: QT3DS-3120 Change-Id: I9c2e967058239db6b2e4bbced42bdea3eeaf559f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Fix dereference of null presTomi Korpipää2019-02-281-0/+3
| | | | | | | | | | Change-Id: I95fcb9631092f368a1ca8ce89a74734386fa4425 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Reduce stereoscopic texture sizes when unusedKaj Grönholm2019-02-282-16/+34
| | | | | | | | | | | | | | | | | | | | Initially and when left & right eye textures are not used, minimize their size. Task-number: QT3DS-3084 Change-Id: Id6b5252cb1a9bc8b9bca64696268b71353a95ca4 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Dragon: Reset bounding volume containersSvenn-Arne Dragly2019-02-271-3/+4
| | | | | | | | | | Change-Id: Iaa87aaf3097d6dcfde81531337bd676b7604c384 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Initialize minFilterType on Q3DSMaterialSvenn-Arne Dragly2019-02-271-0/+1
| | | | | | | | | | Change-Id: Idd424a91e98e47c937c112f5e35769d0bcc3f151 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Force light gathering on pending light visibility change on size updateMiikka Heikkinen2019-02-271-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If there is a pending light visibility change when Q3DSSceneManager::updateSizes is called, lights must be re-gathered or Q3DSSceneManager::updateShadowMapStatus will assert as there are currently inactive lights in layerData->lightsData->lightNodes. Task-number: QT3DS-3066 Change-Id: Ic721715cd4fe4e640a9ce097b660df662ee0ee6d Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Janne Kangas <janne.kangas@qt.io> Reviewed-by: Jere Tuliniemi <jere.tuliniemi@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Drop shadow for distance field textEskil Abrahamsen Blomfeldt2019-02-2711-28/+310
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements a shader for drop shadows + distance field text. The idea here is that we expand the area drawn to accommodate the shadow, then we sample the distance field twice, once for the glyph and once for the shadow. But we have to clamp all texture coordinates to the bounds of the current glyph to avoid sampling outside the glyph. Since we have empty margins around each glyph, this works. At 4 floats extra per vertex, it was the cheapest approach I could think of. Fixes: QT3DS-3090 Change-Id: I402099474266b2e0c61194d7855635acd9b27051 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Set the number of faces to one in distance field textureSvenn-Arne Dragly2019-02-251-0/+1
| | | | | | | | | | | | | | | | | | Otherwise, the backend QTextureImageData uploads an empty QByteArray, leading to a corrupted texture. Change-Id: Icdee50c7dd4ec0de89abf89931b611684953c2eb Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| * Dragon: Remove buffer type from comparisonSvenn-Arne Dragly2019-02-252-2/+1
| | | | | | | | | | | | | | It has been deprecated on QBuffer and is currently uninitialized. Change-Id: Iaf2bcc4cb1647bfd414bcc66a0a9f891f82f5dcc Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Fix uninitialized variable in the animation componentChristian Strømme2019-02-261-2/+2
| | | | | | | | | | | | Change-Id: Icebf9326a46650421e052bd972f5920e6812f7b8 Reviewed-by: Svenn-Arne Dragly <svenn-arne.dragly@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Dragon cleanups and improvements #3Kaj Grönholm2019-02-2549-1279/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Misc cleanups and improvements, including: - Removing duplicate isCompatibleWithFilters from Technique. - Removing dragonshaderjobs and dragonshaderbuilder as they weren't used anywhere. - Removing glDataTypeFromAttributeDataType which exists also in dragonactivatedsurface.cpp - Removing unused dragonframegraph.pri Task-number: QT3DS-3045 Change-Id: I33de06ffd495fa5a53fbe9e60c6cee5026bf1c03 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Dragon cleanups and improvements #2Kaj Grönholm2019-02-2532-583/+58
| | | | | | | | | | | | | | | | | | Small improvements and cleanups while going through dragon sources. Might fix some corner cases but mostly doesn't affect behavior. Task-number: QT3DS-3045 Change-Id: I4c0fe88bbd723c58ab985ee2467ae148d033a83f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Cleanup dragon Renderer and ActivatedSurfaceKaj Grönholm2019-02-257-455/+124
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleanup and small improvements. Some less obvious changes: - Moving private methods to private. - Separate checkContextInfoRequested() from doRender() - m_clearDepth and m_clearStencil were not properly used, they never cached previous value. So removing them and also m_clearColor, setting shouldn't cost ~anything but better make sure they are correct before glClear. - bindParameters() removed as it was unused and same method is in renderer/dragondraw.cpp - isActiveRenderTarget parameter of updateRenderTarget() wasn't really used for anything. Task-number: QT3DS-3045 Change-Id: Ica4379fd5f32f1716b87133e151880f660c6c642 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Fix distance field shader on GLESEskil Abrahamsen Blomfeldt2019-02-222-29/+29
| | | | | | | | | | | | | | | | The shaders were completely missing precision qualifiers. Task-number: QT3DS-3085 Change-Id: I8c05ba3ac5c5f0b82d212e9c42b356c8fd1b7ba2 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
| * Add support for scene2d in dragonMäättä Antti2019-02-218-5/+658
| | | | | | | | | | | | | | | | | | Task-number: QT3DS-2886 Change-Id: Iaaf64365af05de884966fc82319fbf9af93e971d Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Svenn-Arne Dragly <svenn-arne.dragly@qt.io> Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io>
| * Support pregenerated distance field cacheEskil Abrahamsen Blomfeldt2019-02-212-1/+241
| | | | | | | | | | | | | | | | | | | | | | | | | | Unfortunately, this code was never written to be shared, so we currently have to duplicate it. Longer term, the correct approach is to refactor certain OpenGL-parts out from the implementation in Qt Quick, which shouldn't be a huge effort. But for now, we have to duplicate it, since the we are going to be based on 5.12.2 where we can't retroactively do this anyway. Fixes: QT3DS-2833 Change-Id: I5b88b70a69ee4dcb8b13ef0f7408ab9c09cbf254 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
| * Allow dragon Renderer to remove components from EntitiesAndy Nichols2019-02-202-0/+40
| | | | | | | | | | | | | | | | Now it should be possible to hide things via eyeball changes in scenes rendered with dragon. Change-Id: Ib0a76fee9ec9d98c21698e130698fba69fe8ac3e Reviewed-by: Christian Strømme <christian.stromme@qt.io>
| * Fix picking issues when camera has a large far clipMiikka Heikkinen2019-02-201-2/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | The default QVector3D::unproject() implementation checks for qFuzzyIsNull on w of the obj vector and inexplicably changes the value to 1 in that case, which results in completely wrong unprojection. Fixed by reimplementing unproject without qFuzzyIsNull check. Task-number: QT3DS-3062 Change-Id: I2d3dea4f5e85f7fcaf576cef04dbff4fe9e3ad22 Reviewed-by: Antti Määttä <antti.maatta@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Fix camera upvectorMiikka Heikkinen2019-02-201-59/+49
| | | | | | | | | | | | | | | | | | Camera upvector must be calculated from complete rotation matrix to get the correct camera orientation in all cases. Task-number: QT3DS-2988 Change-Id: Ic4709b1c96188dc78e7f60fa6f638373d7b71139 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
| * Fix debug view with dragonKaj Grönholm2019-02-201-0/+3
| | | | | | | | | | | | | | | | | | | | | | Seems debug view expects specific OpenGL state set. This could be ensured also when entering into debug view, but reseting state at start and end of dragon frame shouldn't be too costly either. Task-number: QT3DS-2898 Change-Id: I2f60a3a2be46e0227b313d095e69e106085f903a Reviewed-by: Svenn-Arne Dragly <svenn-arne.dragly@qt.io> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
| * Add null presentation checks to datainputJanne Kangas2019-02-191-0/+9
| | | | | | | | | | | | | | | | | | Check if presentation is null before accessing it. Change-Id: I1a0330663adcf2cb9773c81396ab504c97b06470 Task-id: QT3DS-3077 Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* | Bump version number to 2.4.0Miikka Heikkinen2019-03-111-1/+1
| | | | | | | | | | Change-Id: Ic206d08f9276590050b5d94e901292097d7eef64 Reviewed-by: Antti Määttä <antti.maatta@qt.io>
* | Set the number of faces to one in distance field textureSvenn-Arne Dragly2019-02-191-0/+1
| | | | | | | | | | | | | | | | Otherwise, the backend QTextureImageData uploads an empty QByteArray, leading to a corrupted texture. Change-Id: I5904bc418f7ec01774e5dcabbec614d5b6252a48 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | Fix data input for changing slides in nested componentsChristian Strømme2019-02-121-7/+3
| | | | | | | | | | | | | | | | | | | | Removed useless check that tested if the component was on the master or current slide, as that's not necessarily the case when you have nested components. Fixes: QT3DS-3033 Change-Id: I0af07a36ee7db62c355434ecdf8ee351a1fef505 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Do not cache datainput min/max rangesJanne Kangas2019-02-126-44/+45
|/ | | | | | | | | | | | | Always query datainput range min/max values from the engine level instead of caching the latest value at Q3DSDataInput level. This is to prevent issues with several Q3DSDataInput objects referring to same datainput entry getting out of sync. For QML, change signal is emitted only for local changes, not for changes through other datainput instances. Change-Id: I6e17aeca9ddc6ef59a11fb08ea8e33ccf283b743 Task-id: QT3DS-3001 Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* Code tidy-upsv2.3.0-beta1Janne Kangas2019-02-124-3/+5
| | | | | Change-Id: I30a55df70ab39eaf24ac7194602507d94701dc30 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* Implement datainput metadataJanne Kangas2019-02-1219-4/+281
| | | | | | | | | | | | Add functionality for requesting/setting metadata specific to this datainput to Q3DSDataInput API. Currently offered on C++ side only as the intent for metadata is to facilitate dynamic binding of data sources to data inputs rather than using metadata in end user-facing visualization. Change-Id: Iccda62247cf1dcd857073f92f40d7f955ea43817 Task-id: QT3DS-2993 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* Fix loss of precision warningChristian Strømme2019-02-111-1/+1
| | | | | Change-Id: Ie22ef39284d831dbf38fec9e8fdba34e1c42ad96 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Add some more debug output in the animatorChristian Strømme2019-02-111-3/+6
| | | | | | | | | These are unlikely cases, but we should at least output some hints if they do happen. Also fixed one of the cases that would return instead of continuing processing the rest of the dirty properties. Change-Id: I0580f3c22ed9bbb2611e7987773c74fb6b0c6507 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Remove pending visibility look-up of componentsChristian Strømme2019-02-111-7/+2
| | | | | | | | | We used to check if there was pending changes for a component, as the values were updated at a later time, this is no longer the case as we call setPendingVisibilities() after processing each slide. Change-Id: Ib66ee503f84e95a15cab547a7dc14751b2afd964 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Call syncScene once a new slide is readyChristian Strømme2019-02-111-5/+2
| | | | | | | | | | | All properties should be set and ready to go at this point, so calling syncScene() should make them active. It's a bit unclear what's dependent on the scene being synced, but it can be observed that some objects on nested components (which are not animating) won't get their values set correctly unless we do this. Change-Id: I4ccfc181b8ead84d366300f274c5d0b0a6ad0c7d Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Call reload when activating components in changeStateChristian Strømme2019-02-111-2/+1
| | | | | | | This just uniforms the way a new slide is activated Change-Id: I2bbfac43d505a7ffd1ec48b6b6b62f59544016f2 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* More improvements to the state handlingChristian Strømme2019-02-112-3/+5
| | | | | | | | | | | | - Don't call stop() when changing slides, stop will reset the values to their initial state, i.e., it jumps to time 0. - When moving into Ready state re-evaluate the animation values as these might be needed when updating the dynamic key frames. - Don't hide the master slides objects when going into ready state, those are "always" visible. Change-Id: Ia5d61f940086a5905f36bb4508862e3d23acccb6 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Add api for loading/unloading slide resourcesMäättä Antti2019-02-086-0/+117
| | | | | | | | Preliminary suggestion for the api. Task-number: QT3DS-2661 Change-Id: I1f2e5d2b12272ac128fa155a14d5a09fb1870c53 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* Implement distance field text renderingEskil Abrahamsen Blomfeldt2019-02-0819-48/+1911
| | | | | | | | | | | | | | | | | | | This uses as much as possible from the distance field generator in Qt Gui and the cache logic in Qt Quick. There is a bit of duplicated code here which can be shared if we refactor some things, but that can be done gradually as we increase the required Qt version. For now, this works and looks good at least. It currently does not support drop shadows, so it will fall back to the existing renderer for this. You can also force the old QPainter-based renderer by setting Q3DS_DISTANCE_FIELD_DISABLED to 1. Fixes: QT3DS-1419 Change-Id: I6df62a85ca0ec61609504c929b9c3d126719ba48 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Implement asynchronous image loadingMäättä Antti2019-02-084-61/+158
| | | | | | | | | | | | | Loading image data takes a lot of time, but can be done concurrently. Task-number: QT3DS-2664 Change-Id: I2ee9c74d7601d006fee7578a26727bae859233a4 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Antti Määttä <antti.maatta@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io>