summaryrefslogtreecommitdiffstats
path: root/src/datavisualization/engine/bars3drenderer.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Mark the module as free of Q_FOREACH, except where it isn'tMarc Mutz2023-08-181-0/+2
| | | | | | | | | | | | | | | | | | | | | | The density of Q_FOREACH uses is high here, too high for this author, unfamiliar with this module, to tackle in a short amount of time. But they're concentrated in just a few TUs, so pick a different strategy: Mark the whole module with QT_NO_FOREACH, to prevent new uses from creeping in, and whitelist the affected TUs by #undef'ing QT_NO_FOREACH locally, at the top of each file. For TUs that are part of a larger executable, this requires these files to be compiled separately, so add them to NO_PCH_SOURCES (which implies NO_UNITY_BUILD_SOURCES, too). Created QTBUG-115807 to keep track of this. Ported one that was trivial and where whitelisting of the file with a single Q_FOREACH would have been more work than directly fixing it. Task-number: QTBUG-115807 Change-Id: I2fa6c740e35039baf34115af7d69d6c420e4de10 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* Use SPDX license identifiersLucie Gérard2022-06-131-28/+2
| | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. License files are organized under LICENSES directory. Pick-to: 6.4 Task-number: QTBUG-67283 Change-Id: I3b3112f5a36673b90fff0010f973d020886cf08d Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Add row colors for Bar3DSeriesSami Varanka2021-10-081-3/+10
| | | | | | | | | | | | | Added rowColors property for Bar3DSeries. The property can be used draw the individual rows in the series in different colors. Autotests and a manualtest for the property were added also. Fixes: QTBUG-96682 Change-Id: I5c4f778189d079206500a9289490792584eab2b9 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* Add: Margin between series columns in Bars3DSami Varanka2021-08-241-4/+29
| | | | | | | | | | | | | | Added a new property to Bars3D. The property controls the margin between the columns of series. It can be used to show bars belonging to same column, but different series side by side. Also added autotest for qml and cpp. Fixes: QTBUG-69036 Change-Id: I3c353e9097a8be8cafc05f8f5120e4266baa4a5c Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* Fix bargraph labels face wrong directionSami Varanka2021-06-111-3/+7
| | | | | | | | | | | | | | When the camera's X rotation is 180.0f, the labels were rotated to face wrong direction. The axis title labels do not respect the Abstract3DAxis's titleFixed property. Created a new bugreport QTBUG-94441. Pick-to: 5.15 6.1 Fixes: QTBUG-90371 Change-Id: I80115b8b363a7385dfd2cb1f004a05368549ed48 Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
* Remove custom namespaceTomi Korpipaa2021-01-281-2/+2
| | | | | | Fixes: QTBUG-90400 Change-Id: Ia2f1974a21112bad97724717d073d367c4413a7f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* Add ; to Q_UNUSEDLars Schmertmann2020-06-261-1/+1
| | | | | | | | | This is required to remove the ; from the macro with Qt 6. Task-number: QTBUG-82978 Change-Id: I66f620431011d02cb1542e8ad613dadd28fdd843 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Use QList instead of QVectorJarek Kobus2020-06-251-5/+5
| | | | | | | Task-number: QTBUG-84469 Change-Id: I4dc064b70adb054ca4add2dd662e7227255ff970 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Fix hanging at application exitTomi Korpipaa2019-04-291-7/+9
| | | | | | | Task-number: QTBUG-75256 Task-number: QTBUG-69627 Change-Id: If4221c8fcf783daf4bf6a38dbf1b9633a20eafb0 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
* Use Qt::Alignment instead of the AlignmentFlag enum to represent flagsOlivier Goffart2018-04-101-1/+1
| | | | | | | | | | | | | Because from Qt 5.12, the the right operator| is found in the Qt namespace instead of in the global namespace. One must still add the 'using' statement so this patch can be integrated using a previous qtbase. But the statement can be removed once qtbase is updated. Task-number: QTBUG-67582 Change-Id: Ib79c4623e858988bb55a87ad4fb0c1e0ceee81cf Reviewed-by: Liang Qi <liang.qi@qt.io>
* Copyright file update to GPLMiikka Heikkinen2016-01-121-9/+17
| | | | | Change-Id: Ib264fe1f2cd1589e2ba1ef2dc7d8f3951e125708 Reviewed-by: Tomi Korpipää <tomi.korpipaa@theqtcompany.com>
* Update license headersMiikka Heikkinen2015-10-201-11/+14
| | | | | Change-Id: I0581aefcf9dabc64b05eb8c97b5b92da1fb26299 Reviewed-by: Titta Heikkala <titta.heikkala@theqtcompany.com>
* Copyright header changesMika Salmela2015-04-141-3/+3
| | | | | | | Copyright header changes for 5.5. Change-Id: I0361cfe1ebdb28955cb927700f14cf7b72694421 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@theqtcompany.com>
* Support larger custom meshes.Miikka Heikkinen2014-11-181-1/+1
| | | | | | | | | | Vertex index was limited to unsigned short, meaning even slightly complex meshes couldn't be used. Changed to unsigned int. Also removed unused vertex indexer methods. Change-Id: Iebe62bd3a501dc79ee2857cca28ac0d05bd4a55e Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Change copyright headers.Miikka Heikkinen2014-11-071-7/+7
| | | | | | Change-Id: I453438fee92f18c983c1bef04c68b24a7ff72cf9 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com> Reviewed-by: Mika Salmela <mika.salmela@theqtcompany.com>
* Support for dynamic opengl builds.Miikka Heikkinen2014-10-291-126/+100
| | | | | | Task-number: QTRD-3392 Change-Id: I786bbf5ee9252b92d43d02d6b88ed9b986b4a5eb Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Fix context cleanupMiikka Heikkinen2014-10-131-0/+2
| | | | | | | | | | Context was not getting properly cleaned up in cases where render thread stopped before the cleanup took place. Now we ensure that required cleanup is done before context thread terminates. Change-Id: I1489914dafec928eebb69bac737f6f858ff49432 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Fix screen position based queries in threaded rendering environmentMiikka Heikkinen2014-10-091-0/+1
| | | | | | | | | | | | | | | | QtQuick's threaded renderer doesn't seem to always pair up sync and render (or more accurately, beforeSynchronizing and node's preprocess calls). Sometimes sync comes without a followup render, or there are two syncs in a row, even though the sync is using direct connection. Both of these cases broke the old logic for handling position based queries. Changed the logic to actually ensure we have resolved the query before emitting the relevant signal. Task-number: QTRD-3358 Change-Id: Ica6c8c311f53a06311c21532aaabc18c28556655 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Fixed selecting through the floor bugTomi Korpipää2014-10-081-36/+43
| | | | | | Task-number: QTRD-3359 Change-Id: I418aaef640c05f7af7b860c89f5a5231e3f14c16 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Fixed shadow issue with reflections and no background Tomi Korpipää2014-10-071-2/+3
| | | | | | | Task-number: QTRD-3357 Change-Id: I7ae4460a0666316a6f455f8842d7453513f55705 Change-Id: I7ae4460a0666316a6f455f8842d7453513f55705 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Make background margin configurableMiikka Heikkinen2014-09-301-13/+30
| | | | | | | | | | | Added margin as abstract graph property. If the margin is narrow, the positions of theedge labels of the axes are adjusted to avoid overlap with edge labels on other axes. Task-number: QTRD-3204 Change-Id: I7fa5a04c8f2091519d99689ef2f6cbcf799fb15e Reviewed-by: Mika Salmela <mika.salmela@digia.com> Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Implement zooming to cursorMiikka Heikkinen2014-09-261-5/+15
| | | | | | | | | Zooming to cursor is now default operating mode of the default input handler. Task-number: QTRD-3263 Change-Id: I5699fc0ce7393059538972cd52f31f06d87e3d8d Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Allow setting the floor level on bar graphs.Miikka Heikkinen2014-09-221-17/+30
| | | | | | Task-number: QTRD-3313 Change-Id: Ie0f8e36af8698081a6937c360043773da895b6e6 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Change custom labels to use label shaderMiikka Heikkinen2014-09-191-12/+0
| | | | | | | | | This fixes the problem with specular highlight making camera-facing labels unreadable. Task-number: QTRD-3276 Change-Id: If16424b07a1f3362428980353c5fb5213c33d06b Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Fix to slice crash bug fixTomi Korpipää2014-09-161-2/+5
| | | | | | | Task-number: QTRD-3301 Change-Id: Ia0ae6d5e3ac9aabc9af9199df27bbbe7f7908d60 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Invalid slice usage crash fixedTomi Korpipää2014-09-161-0/+11
| | | | | | | | Task-number: QTRD-3301 Change-Id: I0e39348a2e9392b4c1f0bd7ef26c5613272460e2 Reviewed-by: Pasi Keränen <pasi.keranen@digia.com> Reviewed-by: Titta Heikkala <titta.heikkala@digia.com>
* Limit volume to axis rangesMiikka Heikkinen2014-09-101-6/+46
| | | | | | | | | The volume object that would go partially outside axis ranges is scale and repositioned so that it only renders the portion that is inside the axis ranges. Change-Id: I792494e437998ba6276f58fab645767276c1476d Reviewed-by: Mika Salmela <mika.salmela@digia.com>
* Add option to use low definition volume shader.Miikka Heikkinen2014-09-021-6/+2
| | | | | | | | Low definition volume shader samples the texture at even intervals, so it will sometimes skip texels, causing flickering. Change-Id: Iee6cb0e8893498b89ce1a40f34701a53d100283e Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Mac reflection bug fixedTomi Korpipää2014-08-271-6/+4
| | | | | | | + some mingw & clang compilation fixes Change-Id: Ib4cd5534d9d4e630c021f3d9901114983cdc26eb Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Reflection API addedTomi Korpipää2014-08-261-104/+74
| | | | | | | Task-number: QTRD-3287 Change-Id: I6c06b8fe025e0f1f87be00be906cab0e1f18a19f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Implement volume rendering supportMiikka Heikkinen2014-08-181-5/+10
| | | | | | | | New subclass of QCustom3DItem, QCustom3DVolume is provided. The documentation for the example will be done in a separate commit. Change-Id: Idb3fdb0654c6bec7606ca012b75852a5a8412397 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Enable camera targeting.Miikka Heikkinen2014-08-061-48/+45
| | | | | | | | | | | | | | | Also fix custom item positioning in absolute mode as it was completely broken in bars and z-coord was flipped in others. Clarified Q3DObject::position property usage, namely that it is reserved for internal use for now. Some refactoring also done. Task-number: QTRD-2567 Change-Id: I5da65b83a2f8ecf20f8fd054e59748278ef1a714 Reviewed-by: Titta Heikkala <titta.heikkala@digia.com> Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Improved the visuals in slice modes.Miikka Heikkinen2014-07-041-3/+6
| | | | | | | | | | | | | | | Grid lines should no longer vanish into white background due to excessive ambient light multiplier when using high ambient with no specular. I'm still not happy with how bars slice mode colors look. The colors seem washed out compared to main view. Also, on bars, some specular is needed to make bars look 3D, but too much makes it ugly. Also fixes some misc issues in surface slice mode. Task-number: QTRD-3237 Change-Id: I4bed3d922cbc8f5191cc01ab3396849db767cae9 Reviewed-by: Mika Salmela <mika.salmela@digia.com>
* Adjust background margins based on angular labels and titleMiikka Heikkinen2014-06-301-0/+2
| | | | | | | | Also separated the vertical and horizontal background margins. Task-number: QTRD-3184 Change-Id: I988217d4df7749585dd85b5ea8f3f50254dca6ad Reviewed-by: Mika Salmela <mika.salmela@digia.com>
* Polar graph support, phase oneMiikka Heikkinen2014-06-261-13/+10
| | | | | | | | | | - Polar property for toggling the polar mode - Example added. Example docs will be added in another patch once all of the functionality the example needs has been implemented. - Only surface graph supports polar so far. Scatter to be added later. Change-Id: I54d36f764ac1771ac88f73a5f3a2142f2309f6e8 Reviewed-by: Mika Salmela <mika.salmela@digia.com>
* Added some extra checking for selection texture creationMiikka Heikkinen2014-06-241-1/+2
| | | | | Change-Id: Iedeaa2581c32b6d46168568fef736b234ac17e95 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Bars: Moved bar, background and grid line drawing to separate methodsTomi Korpipää2014-06-241-113/+270
| | | | | | | + Added floor reflection support in ifdefs Change-Id: I1060aee1bc8f7a0360ad01675c36c0f1a2120f1c Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Fix missing axis titles with zero rotation and fixed titlesMiikka Heikkinen2014-06-061-7/+8
| | | | | Change-Id: I026578b224772fe9d96f6f7789e253d433690091 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Change label polygon offset to follow draw orderMiikka Heikkinen2014-06-051-3/+6
| | | | | Change-Id: I6b0bbb458fe9eae9664cd50f9b20f672b08cf4b9 Reviewed-by: Mika Salmela <mika.salmela@digia.com>
* Clean up Tomi Korpipää2014-06-041-18/+29
| | | | | | | Task-number: QTRD-3149 Change-Id: I37ae7bc7e88b7d8a2c81585333ab87e7fcb8fcc0 Change-Id: I37ae7bc7e88b7d8a2c81585333ab87e7fcb8fcc0 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Misc fixes for bugs found during examples testingMiikka Heikkinen2014-06-031-1/+1
| | | | | | | | | | | | - qmlbars TableView year/month display got messed up when scrolled. - qmllegend black background on transparent item bug was back due to some changes in 5.3. Worked around the issue differently. - qmloscilloscope displayed warnings about circular property binding. - Incorrect count was used to determine amount of labels for rows in bar charts. Change-Id: Id5851019af258c256a92648561bb8ce766993b5c Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Clean up renderersTomi Korpipää2014-06-031-9/+0
| | | | | | | Task-number: QTRD-3149 Change-Id: I71b9b7533ad3730d0d203c3d07e66d824b690fbb Reviewed-by: Titta Heikkala <titta.heikkala@digia.com> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Misc fixes found while valgrinding.Miikka Heikkinen2014-06-021-3/+9
| | | | | Change-Id: If744721eff62f07f20bff95ca815ca80ca50fee1 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Fix various issuesMiikka Heikkinen2014-06-021-7/+11
| | | | | Change-Id: I4a6d4775f3ca578370a9ce23491bddcb0f5486ec Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Added CustomLabelItemTomi Korpipää2014-05-281-1/+1
| | | | | | Task-number: QTRD-3135 Change-Id: Ie13c7ab5cbfca2eef88ed4ca17eaf46f2aeb4788 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Fix labels transparency within each axisMiikka Heikkinen2014-05-281-81/+104
| | | | | | Task-number: QTRD-3141 Change-Id: I8ca51b411e2d92e0c615c81d215d89575d614acd Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Optionally show axis titles on the graphMiikka Heikkinen2014-05-271-28/+33
| | | | | | Task-number: QTRD-2961 Change-Id: I6a344156bd29fa8fb1ede0546af4d0e67e5e2db4 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Added API for changing data aspect ratioTomi Korpipää2014-05-261-0/+5
| | | | | | Task-number: QTRD-3144 Change-Id: I9acd1be13083d7fbbed840882260a60f46c5f698 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Fix misc minor issuesMiikka Heikkinen2014-05-221-1/+1
| | | | | | | | | | - Rename bars background mesh more logically - Reorder ElementAxis enums logically - Change the sun in rotations example to a custom item Task-number: QTRD-3132 Change-Id: I00dacb68ebce222edc1a732cf7d14f1660934b36 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>
* Cache ObjectHelper instancesMiikka Heikkinen2014-05-221-15/+9
| | | | | | Task-number: QTRD-2792 Change-Id: I90d83bd9b73a0f337fd26f1b92000e72b3ec0607 Reviewed-by: Tomi Korpipää <tomi.korpipaa@digia.com>