summaryrefslogtreecommitdiffstats
path: root/tests/auto/render/texture
Commit message (Collapse)AuthorAgeFilesLines
* Update QAbstractTexture message handlingMike Krus2019-10-111-18/+10
| | | | | Change-Id: I5c0ff05d405766b2e0aee992ee1c150b5a0cf059 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Update QAbstractTexture to use direct sync modeMike Krus2019-09-181-97/+37
| | | | | Change-Id: Iaac3196e9848c0a5a85e75cb61650813c1b70ab0 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Do direct notification of backend nodeswip/refactorMike Krus2019-08-281-30/+25
| | | | | | | | | | | | | | | | | Since aspect manager is now on main thread, we can directly update backend nodes safely. Track nodes which have changed properties and notify the backend nodes as part of the frame loop. This avoid allocating and delivering many change messages. To follow: - implement on all nodes - look at backend to frontend syncing - figure out what to do with non property messages (components added/removed, commands, ...) Change-Id: Ia0c442b0528e728c4324d168200bae021bc29266 Reviewed-by: Mike Krus <mike.krus@kdab.com> Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
* Make it possible to partially update a texturePaul Lemire2019-03-201-0/+44
| | | | | | | | | | - Introduce QTextureDataUpdate which contains information about the update - QAbstractTexture::updateTexture function added - Add manual test texture-updates-cpp - Add unit tests for GLTexture and complete other texture tests Change-Id: I1b792f2075830ce05cc8e04cc68110141b5571d6 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Merge remote-tracking branch 'origin/5.12' into devQt Forward Merge Bot2018-12-251-0/+23
|\ | | | | | | Change-Id: I13dfef5918cada019dfa29a28a8eee6a6efa7e27
| * Texture: initialize internal format to NoFormatPaul Lemire2018-12-191-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Format was initialized to RGBA8_UNorm on TextureProperties. This had the side effect that if you created a TextureLoader entry with no source yet set, the backend would try to load and return early since no texture data had yet been generated. Yet it would still send a notification change with the format (which was RGBA8_UNorm instead of NoFormat) back to the frontend QTextureLoader. This would prevent the QTextureLoader from later being loaded correctly with the format actually read from the image file. Also updated QTextureData/QTextureImageData/QTextureFromSourceLoader for consistency. Change-Id: I23e2287fac297b9b8901476715b1bc1e78c6342b Task-number: QTBUG-72651 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com>
* | Add QSharedGLTexturePaul Lemire2018-10-081-0/+13
|/ | | | | | | | | | | | | QAbstractTexture subclass that will allow to make Qt3D work with a texture id created by another GL engine on a shared context. [ChangeLog][Qt3DRender] Add QSharedGLTexture to allow creating a Qt3D from an OpenGL texture id. Change-Id: Ic5b19eae6ebc7aca7e6372d62217348f99db19df Task-number: QTBUG-69918 Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com>
* Improve backend texture unit testsPaul Lemire2018-08-131-0/+186
| | | | | Change-Id: Ie7baba99e03defcd3d8194fd11838a86d1680060 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Fix: Do not enforce TextureImage to be parented only by TexturePaul Lemire2018-07-181-0/+66
| | | | | | | | | | | | | | | | | | | | This behavior prevented using TextureImage not directly parented by the Texture that uses them (assert would be triggered). In turn, this also prevents sharing a TextureImage among several Texture instances which is counter productive since this is where the data is actually stored. This patch fixes this issue. It removes all direct coupling between Texture and TextureImages. Now Texture only contains the list of TextureImage ids it references. This allows to not make look-ups into the TextureImageManager to retrieve handles, which could be an issue if TextureImages have not yet had their backend created. TextureImage doesn't keep track of the referencing texture that uses it anymore. Instead, we let the renderer do the job of checking if any of the TextureImage referenced by a Texture has changed to trigger actual Texture update. Change-Id: I3c63379d0f4b314e9b53f225870eeaded0bb4aec Task-number: QTBUG-69407 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Merge branch '5.9' into devSean Harmer2017-08-191-4/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/render/backend/renderer.cpp src/render/backend/renderview.cpp src/render/graphicshelpers/graphicscontext_p.h src/render/graphicshelpers/graphicshelperes2_p.h src/render/graphicshelpers/graphicshelpergl2_p.h src/render/graphicshelpers/graphicshelpergl3_2_p.h src/render/graphicshelpers/graphicshelpergl3_3_p.h src/render/graphicshelpers/graphicshelpergl4_p.h src/render/graphicshelpers/graphicshelperinterface_p.h src/render/jobs/pickboundingvolumejob.cpp tests/auto/animation/clipanimator/tst_clipanimator.cpp tests/auto/auto.pro tests/manual/manual.pro Also disabled the QQmlMetaType codepaths following commit 49a11e882059ee1729f776722e085dd21d378c36 in qtdeclarative. The QQmlMetaType codepaths will be re-enabled once a qt5.git integration has succeeded. Change-Id: Ia654d75425e6d406c472d19864383612208cad2b
| * Use QSharedPointer::create() moreMarc Mutz2017-07-221-4/+4
| | | | | | | | | | | | | | | | | | | | This is the result of running the (experimental) clang-tidy check qt-modernize-qsharedpointer-create Discarded changes: none. Change-Id: Ic6368521ebf5841267ffe7917cc652627f7b26a7 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | Renderer: add more dirty flags and launch jobs based on thatPaul Lemire2017-06-011-0/+10
|/ | | | | | | | | This allows to launch the boundings volumes and transform related jobs only when transforms or geometry have changed. This will be extended in the following commits to Materials, FrameGraph... Change-Id: I71bc61471639ead32de71c9e78952fb0741ef185 Reviewed-by: Mike Krus <mike.krus@kdab.com>
* Texture backend refactoringWieland Hagen2016-11-141-11/+11
| | | | | | | | | | | | | | | | | Texture node only tracks frontend properties and a non-owning pointer to the GLTexture The backend Texture node basically just keeps track of it's properties, parameters, and data. It relies on the GLTextureManager to provide a GLTexture that matches these properties/parameters/data. If a backend Texture node is created or modified, it is marked dirty and added to the TextureManager's list of dirty textures. At the start of each frame, all gathered dirty textures will ask the GLTextureManager for a GLTexture instance that matches the texture properties. Change-Id: Ie436e52ce644a489552cad1633f2233b8c15803f Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Allow setting sample count for multisample targetsMauro Persano2016-08-121-0/+31
| | | | | | | | | Adds new property which allows you to change the number of samples per texel in a texture. Only used for multisample render targets (Texture2DMultisample and Texture2DMultisampleArray). Change-Id: I76934c3af125fb97f61e35cb4db84799bd17a6ab Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add basic unit tests for texture classesMauro Persano2016-08-082-0/+247
Change-Id: Ia3cfdbc085204dba45019394996bcd09fe415bd8 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>