Trusted Software Excellence across Desktop and Embedded
Take a glance at the areas of expertise where KDAB excels ranging from swift troubleshooting, ongoing consulting and training to multi-year, large-scale software development projects.
Find out why customers from innovative industries rely on our extensive expertise, including Medical, Biotech, Science, Renewable Energy, Transportation, Mobility, Aviation, Automation, Electronics, Agriculture and Defense.
High-quality Embedded Engineering across the Stack
To successfully develop an embedded device that meets your expectations regarding quality, budget and time to market, all parts of the project need to fit perfectly together.
Learn more about KDAB's expertise in embedded software development.
Where the capabilities of modern mobile devices or web browsers fall short, KDAB engineers help you expertly architect and build high-functioning desktop and workstation applications.
Extensible, Safety-compliant Software for the Medical Sector
Create intelligent, patient-focused medical software and devices and stay ahead with technology that adapts to your needs.
KDAB offers you expertise in developing a broad spectrum of clinical and home-healthcare devices, including but not limited to, internal imaging systems, robotic surgery devices, ventilators and non-invasive monitoring systems.
Building digital dashboards and cockpits with fluid animations and gesture-controlled touchscreens is a big challenge.
In over two decades of developing intricate UI solutions for cars, trucks, tractors, scooters, ships, airplanes and more, the KDAB team has gained market leading expertise in this realm.
Build on Advanced Expertise when creating Modern UIs
KDAB assists you in the creation of user-friendly interfaces designed specifically for industrial process control, manufacturing, and fabrication.
Our specialties encompass the custom design and development of HMIs, enabling product accessibility from embedded systems, remote desktops, and mobile devices on the move.
Legacy software is a growing but often ignored problem across all industries. KDAB helps you elevate your aging code base to meet the dynamic needs of the future.
Whether you want to migrate from an old to a modern GUI toolkit, update to a more recent version, or modernize your code base, you can rely on over 25 years of modernization experience.
KDAB offers a wide range of services to address your software needs including consulting, development, workshops and training tailored to your requirements.
Our expertise spans cross-platform desktop, embedded and 3D application development, using the proven technologies for the job.
When working with KDAB, the first-ever Qt consultancy, you benefit from a deep understanding of Qt internals, that allows us to provide effective solutions, irrespective of the depth or scale of your Qt project.
Qt Services include developing applications, building runtimes, mixing native and web technologies, solving performance issues, and porting problems.
KDAB helps create commercial, scientific or industrial desktop applications from scratch, or update its code or framework to benefit from modern features.
Discover clean, efficient solutions that precisely meet your requirements.
Boost your team's programming skills with in-depth, constantly updated, hands-on training courses delivered by active software engineers who love to teach and share their knowledge.
Our courses cover Modern C++, Qt/QML, Rust, 3D programming, Debugging, Profiling and more.
The collective expertise of KDAB's engineering team is at your disposal to help you choose the software stack for your project or master domain-specific challenges.
Our particular focus is on software technologies you use for cross-platform applications or for embedded devices.
Since 1999, KDAB has been the largest independent Qt consultancy worldwide and today is a Qt Platinum partner. Our experts can help you with any aspect of software development with Qt and QML.
KDAB specializes in Modern C++ development, with a focus on desktop applications, GUI, embedded software, and operating systems.
Our experts are industry-recognized contributors and trainers, leveraging C++'s power and relevance across these domains to deliver high-quality software solutions.
KDAB can guide you incorporating Rust into your project, from as overlapping element to your existing C++ codebase to a complete replacement of your legacy code.
Unique Expertise for Desktop and Embedded Platforms
Whether you are using Linux, Windows, MacOS, Android, iOS or real-time OS, KDAB helps you create performance optimized applications on your preferred platform.
If you are planning to create projects with Slint, a lightweight alternative to standard GUI frameworks especially on low-end hardware, you can rely on the expertise of KDAB being one of the earliest adopters and official service partner of Slint.
KDAB has deep expertise in embedded systems, which coupled with Flutter proficiency, allows us to provide comprehensive support throughout the software development lifecycle.
Our engineers are constantly contributing to the Flutter ecosystem, for example by developing flutter-pi, one of the most used embedders.
KDAB invests significant time in exploring new software technologies to maintain its position as software authority. Benefit from this research and incorporate it eventually into your own project.
Start here to browse infos on the KDAB website(s) and take advantage of useful developer resources like blogs, publications and videos about Qt, C++, Rust, 3D technologies like OpenGL and Vulkan, the KDAB developer tools and more.
The KDAB Youtube channel has become a go-to source for developers looking for high-quality tutorial and information material around software development with Qt/QML, C++, Rust and other technologies.
Click to navigate the all KDAB videos directly on this website.
In over 25 years KDAB has served hundreds of customers from various industries, many of them having become long-term customers who value our unique expertise and dedication.
Learn more about KDAB as a company, understand why we are considered a trusted partner by many and explore project examples in which we have proven to be the right supplier.
The KDAB Group is a globally recognized provider for software consulting, development and training, specializing in embedded devices and complex cross-platform desktop applications.
Read more about the history, the values, the team and the founder of the company.
When working with KDAB you can expect quality software and the desired business outcomes thanks to decades of experience gathered in hundreds of projects of different sizes in various industries.
Have a look at selected examples where KDAB has helped customers to succeed with their projects.
KDAB is committed to developing high-quality and high-performance software, and helping other developers deliver to the same high standards.
We create software with pride to improve your engineering and your business, making your products more resilient and maintainable with better performance.
KDAB has been the first certified Qt consulting and software development company in the world, and continues to deliver quality processes that meet or exceed the highest expectations.
In KDAB we value practical software development experience and skills higher than academic degrees. We strive to ensure equal treatment of all our employees regardless of age, ethnicity, gender, sexual orientation, nationality.
Interested? Read more about working at KDAB and how to apply for a job in software engineering or business administration.
In the previous article we learned about the requirements and high-level architecture of Qt3D 2.0. In order to put some of this into context and to give you a concrete example of how it looks to draw something in Qt3D using the QML API, we will now briefly show the important parts of one of the simple examples that will ship with Qt3D. We will start off simple and just draw a single entity (a trefoil knot) but to make it slightly more interesting we will use a custom set of shaders to implement a single-pass wireframe rendering method. This is what we will draw:
As mentioned in the previous article, the renderer aspect looks for entities that have some geometry, a material and optionally a transformation. These are all specified in the form of subclasses of QComponent which have been exported to the QML engine in the form of Mesh, Material and Transform respectively. So let's use these components to make a custom QML item in TrefoilKnot.qml
importQt3D2.0importQt3D.Render2.0Entity{id: root
property alias x: translation.dx property alias y: translation.dy property alias z: translation.dz property alias scale: scaleTransform.scale property alias theta: thetaRotation.angle property alias phi: phiRotation.angle property Material material
components:[ transform, mesh, root.material]Transform{id: transform
Translate{id: translation }Scale{id: scaleTransform }Rotate{id: thetaRotation; axis:Qt.vector3d(1.0,0.0,0.0)}Rotate{id: phiRotation; axis:Qt.vector3d(0.0,1.0,0.0)}}Mesh{id: mesh
source:":/assets/obj/trefoil.obj"}}
Let's break this down to see what's going on here. We start off by importing the Qt3D 2.0 module that provides the Entity type and value type helpers like Qt.vector3d(). We also import the Qt3D.Render 2.0 module that provides the components and other types picked up by the renderer aspect. If we were using components from other aspects, then we would also need to import the corresponding QML module here too.
We then use Entity as the root element of the custom QML type exposing some custom properties just as you would with any other type in QML.
Entities, Entities, Everywhere
In addition to aggregating components, Entity objects can be used to group child objects together. This is analogous to how Item is used in Qt Quick 2.
At the bottom of the TrefoilKnot.qml file we instantiate a Transform component and a Mesh component. The Mesh component is very simple. We use its source property to load in a static set of geometry (vertex positions, normal vectors, texture coordinates etc.) from a file in the Wavefront Obj format. This data was exported from the excellent and free Blender application. The Transform component specifies how the renderer should transform the geometry when it is drawn with the OpenGL pipeline. Exactly how this happens is a topic for a future article. For now, simply be happy that you are able to combine an ordered set of transformations into a single Transform component and that your shaders will have this information available to them automatically via some standard named uniform variables.
Dynamic Per-Vertex Data
In addition to the Mesh element, Qt3D also allows dynamic generation of per-vertex attribute data via some C++ hooks called by the task-based engine.
Simply instantiating components is not enough however. In order for them to imbue special behaviour on an entity, the entity must aggregate the components by means of its components property. This allows components to be shared between multiple entities very easily. In this example we have components for the transform and mesh which are contained within our custom type. The final component, of type Material is, in this case, provided by means of a property on the TrefoilKnot itself. This allows users of this type to easily customise the appearance of the entity, which we will make use of shortly.
Now that we have defined a custom entity, let's see how to use it to actually get our desired result. The code for our main.qml file looks like this:
importQt3D2.0importQt3D.Render2.0importQtQuick2.1asQQ2Entity{id: root
// Use the renderer configuration specified in ForwardRenderer.qml// and render from the mainCameracomponents:[FrameGraph{activeFrameGraph:ForwardRenderer{camera: mainCamera
}}]BasicCamera{id: mainCamera
position:Qt.vector3d(0.0,0.0,25.0)}Configuration{controlledCamera: mainCamera
}WireframeMaterial{id: wireframeMaterial
effect:WireframeEffect{}ambient:Qt.rgba(0.2,0.0,0.0,1.0)diffuse:Qt.rgba(0.8,0.0,0.0,1.0)}TrefoilKnot{id: trefoilKnot
material: wireframeMaterial
}}
We start off again with the same import statements as before but this time we also add in a namespaced import for the Qt Quick 2.1 module as we will need this shortly for some animations. Once again we also use Entity as the root element simply to act as a parent for its children. In this sense, Entity is much like the Item element type from Qt Quick.
Here, we will gloss over the FrameGraph component as that is worthy of an entire article on it's own. For now, it suffices to say that the contents of the ForwardRenderer type is what completely configures the renderer without touching any C++ code at all. It's pretty cool stuff but you'll have to wait for the details as this is already a long article. Similarly, please ignore the Configuration element. This is a temporary hack that is needed to have mouse control of the camera until we finish implementing that part correctly using aspects and components.
The BasicCamera element is a trivial wrapper around the built-in Camera type, that as you can probably deduce, represents a virtual camera. It has properties for things like the near and far planes, field of view, aspect ratio, projection type, position, orientation etc.
Multiple Cameras
It is trivial to use multiple cameras and choose between them using the framegraph for all or part of the scene rendering. We will cover this in a future article.
Next up we have the WireframeMaterial element. This is custom type that wraps up the built-in Material type. Qt3D has a robust and very flexible material system that allows multiple levels of customisation. This caters for different rendering approaches on different platforms or OpenGL versions; allows multiple rendering passes with different state sets; provides mechanisms for overriding of parameters at different levels; and also allows easy switching of shaders -- all from C++ or using QML property bindings. Once again, to do this topic justice would require more space than we have here so we will defer it for another time. For now, the take away point is that properties on a Material can easily be mapped through to uniform variables in a GLSL shader program that is itself specified in the referenced effect property.
Supported Shader Stages
Qt3D supports all of the OpenGL programmable rendering pipeline stages: Vertex, tessellation control, tessellation evaluation, geometry and fragment shaders. Compute shaders require a little more API work for getting data into and out of them before they are fully supported.
Instantiating the TrefoilKnot and setting our material on it is simplicity itself. Once we have done that and with the parts we have glossed over, the Qt3D engine in conjunction with the renderer aspect has enough information to finally render our mesh using the material we specified.
Of course we can go further and make things a little more interesting by making use of the animation elements provided by Qt Quick 2. When we animate properties of our custom TrefoilKnot or the Wireframematerial, the properties of its components get updated by means of the usual QML property binding mechanism. For example:
The property updates are noticed by the QNode base class and are automatically sent through to the corresponding objects in the renderer aspect. The renderer then takes care of translating the property updates through to new values for uniform variables in the GLSL shader programs. You can find the full source code for this example in the Qt 5 git repository (see below) and when you run it gives the following view of a trefoil knot with the width of the wireframe lines pulsing. All the heavy lifting is being done by the GPU of course. All the CPU has to do is the property animations and the little bit of work to translate the scenegraph and framegraph into raw OpenGL calls.
Even More Win?
In the future, even the animations will be able to be performed across multiple cores by providing a specialised animation aspect. It is also already possible to animate on the GPU via a custom shader program and material.
What Is the Status of Qt3D?
As of December 2014, most of the core framework of Qt3D is now in place. There are a few areas that we want to tidy up and extend before release to make it easier for users to extend. For the renderer aspect, most of the features for an initial release are working. We have just finished implementing the first pass of using data gathered from entities in the scenegraph to populate Uniform Buffer Objects (UBOs) that can be bound to OpenGL shader programs to make large amounts of data readily available. Typical use cases for UBOs are for sets of material or lighting parameters but they can be used for anything you can think of.
The two big things that we have yet to implement for the renderer aspect are:
Support for instanced rendering. Instancing is a way of getting the GPU to draw many copies (instances) of a base object that varies in some way for each copy. Often, in position, orientation, colour, material properties, scale etc. Our plan is to provide an API similar to Qt Quick's Repeater element. In this case the delegate will be the base object and the model will provide the per-instance data. So whereas an entity with a Mesh component attached eventually gets transformed into a call to glDrawElements, an entity with a instanced component will be translated into a call to glDrawElementsInstanced.
Qt Quick 2 Integration. There are a number of ways in which Qt Quick 2 could be integrated with Qt3D (or vice versa). For example, you may simply wish to embed a Qt3D scene into a custom Qt Quick 2 item to put it into your UI. Alternatively, you may want to overlay a Qt Quick 2 scene as a UI over your Qt3D scene. You may also want to be able to use Qt Quick 2 to render into a texture and then use that texture within your Qt3D scene, perhaps to apply it to some geometry such as a sign post. With a custom Qt Quick 2 item based on QQuickFramebufferObject and by making use of QQuickRenderControl all of these options should be possible.
In addition, we have yet to implement a sane set of default materials that are ready to use out of the box. The materials example that is included in the Qt3D examples shows a good selection of what some defaults may look like. They need making a little more generic and testing on other platforms, particularly OpenGL ES 2 and ES 3.
Beyond the renderer, the other aspect to be shipped when we release Qt3D 2.0 will be the keyboard and mouse input aspect. Support for keyboard input is already implemented and is usable. Mouse support will come in the New Year. For now we have the hacked together solution mentioned in the above wireframe example for controlling the camera.
Qt3D API
Please note that the Qt3D API is not yet frozen. The API will change before release, but hopefully not by much.
What Can You Do To Help Qt3D?
So far Qt3D 2.0 has been almost entirely designed and implemented by KDAB engineers. I would like to highlight the efforts of Paul Lemire, James Turner, Kevin Ottens, Giuseppe D'Angelo and Milian Wolff who have done a huge amount of work to rebuild Qt3D from the ground up. A lot of work has gone into Qt3D, much of it not visible, in the form of prototypes that were discarded and never saw the light of day, API reviews, testing, debugging, and profiling. This has resulted in over 1200 commits since we moved development onto the public Qt git repositories.
Most of the work in rewriting Qt3D has been funded by our employer, KDAB, and also in the spare time of the above people. Recently we were fortunate enough to get some external funding to help implement some of the missing functionality of Qt3D. This was a fantastic boost for us, because it allowed KDAB to have Paul Lemire focus primarily on Qt3D for an extended period without distraction in addition to facilitating an incredibly helpful API review.
Funding or Using Qt3D
If you wish to help contribute to Qt3D (or any other part of Qt), but you don't have the time or resources to write patches or if you just wish to invest in Qt3D with some R&D money you have left over, then please do consider funding us to do work in Qt3D on your behalf. Also, the best way to drive new features is to use a technology in the real world, so if you want to use Qt3D (or any other part of Qt) in your next project then please get in touch with us.
If you want to get involved directly with Qt3D or if you just want to try it out, then take a look at how to build Qt 5 from source and drop in to the #qt-3d channel on freenode. You will find a bunch of us in there most of the time. If you need help getting up to speed or if you want something to work on or need some guidance around the architecture please feel free to ping us in there or on the development mailing list. Please use the dev branch to build Qt3D.
We hope to release Qt3D 2.0 along with Qt 5.5.0 in the spring, but the more help or funding we can get with implementation, documentation, testing, and examples the better shape Qt3D will be in for everybody. So thank you to everybody that has provided help and feedback so far. We are happy with the direction Qt3D is going in and we are really looking forwards to an initial release and many more releases in the future.
About KDAB
Trusted software excellence across embedded and desktop platforms
The KDAB Group is a globally recognized provider for software consulting, development and training, specializing in embedded devices and complex cross-platform desktop applications. In addition to being leading experts in Qt, C++ and 3D technologies for over two decades, KDAB provides deep expertise across the stack, including Linux, Rust and modern UI frameworks. With 100+ employees from 20 countries and offices in Sweden, Germany, USA, France and UK, we serve clients around the world.
Awesome work! Way better than Qt3D 1.0. Keep up the hard work. I can't wait until the next article.
8 - Jan - 2015
Sean Harmer
Thank you. Still plenty to do and rough edges to polish but we're getting there I think.
8 - Jan - 2015
Philip
I downloaded the source and ran the examples. They all seemed to work. Many of them crashed at on closing them.
On another note, does a3d support anti-aliasing out of the box? Does the frame graph support MSAA? I'm assuming that I could easily implement SSAA or FXAA in the frame graph?
8 - Jan - 2015
Sean Harmer
Yeah, known issue. I was hoping to resolve it over Xmas but ended up tracking down an issue with qdoc. I have some time assigned this month and that bug is high on my list.
8 - Jan - 2015
Sean Harmer
We will offer a property for enabling MSAA. Yes, supporting SSAA and FXAA will be trivial via the framegraph and a custom post-proc shader.
8 - Jan - 2015
Philip
Sweet! This is definitely an exciting technology!
9 - Jan - 2015
Stephane
This is really exciting, also the component approach i like a lot.
all the best for Qt3D !
Can't wait for next article :)
12 - Jan - 2015
Jasem Mutlaq
Wow, this is very exciting indeed and I am glad Qt3D is coming back stronger than ever! Excellent job KDAB!
13 - Jan - 2015
Cera
Great work guys.
17 - Jan - 2015
jiangcaiyang
Nice work! I want to contribute my code and technology to KADB on Qt 3D work! Currently I have Android, iOS and Window Phone devices available for testing Qt 3D, in addition, I have a few code want to live happy with Qt 3D. So I want to know is it possible to write a custom Model format parser with Qt 3D? Is it to write under Assimp library or under one of Qt 3D's interface. This format support skeleton animation but the animation stays in another animation file. How to join KDAB to contribute my code to Qt 3D?
17 - Jan - 2015
Sean Harmer
Thank you! You are most welcome to join us improving Qt3D. We are developing Qt3D in the open as part of the overall Qt Project. You can usually find us hanging out on #qt-3d channel on freenode. Alternatively you can reach us via the development@qt-project.org mailing list.
Any help in making Qt3D work on Android, iOS or Windows Phone would be most welcome indeed. We think the necessary abstractions are in place but I'm sure there will be some build time and runtime issues to resolve.
We would also love to help you get your skeletal animation format supported for Qt3D 2.1. It's something we have on the roadmap but we have yet to start development of a skeletal animation aspect so this would be a great area for you to dive into. Qt3D has hooks for loading custom mesh formats but we do not yet have anything to support skeletal animation. I don't think this should be too hard to add in however.
Hope to see you online shortly!
21 - Jan - 2015
jiangcaiyang
Thank you for your reply!
These time in addition to work with my project currently, I want to look deep into the awesome Qt 3D. Recently I want to download Qt 5.5 together with Qt 3D and try to learn some concept on Qt 3D. I'd be happy to go forward with KDAB and Qt contributors!
1 - Apr - 2015
H.O.
Thanks for the great work. For my current project I need the integration of QtQuick 2 and Qt3D for UI implementation as you already mentioned above. Do you have an example for that? The clues regarding QQuickFramebufferObject and QQuickRenderControl are not helpful, cause I'm totally new to QtQuick and Qt3D. Any help would be great! Thanks in advance!
1 - Apr - 2015
Sean Harmer
Wrap your 3D world in a Scene3D{} element and use this like any other Qt Quick 2 item. Take a look at the Scene3D example that ships with Qt3D.
1 - Apr - 2015
H.O.
Thanks, that was really quick!
Sadly I still did not get it working cause now in the combination of Qt3D and QtQuick I get a message which says: "GLSL 1.50 is not supported. Supported versions are: 1.10, 1.20, 1.30, 1.00 ES, and 3.00 ES" Somehow he tries to compile a fragment shader. This happens only if I try to load files exported from Blender (*.obj). The above mentioned example works well.
1 - Apr - 2015
Sean Harmer
Seems you are trying to use a GLSL shader in one of the materials that is assuming OpenGL 3.2 but your system doesn't have that. Can you track down which shader is giving that error?
It happens when I apply no special material at all and even as well when I apply the WireframeMaterial from your example. Thanks a lot for your help!
1 - Apr - 2015
Sean Harmer
The wireframe material is expected to require OpenGL 3, but the default material should work anywhere. Please file a bug at bugreports.qt.io for this with a small test case and a description of your setup.
1 - Apr - 2015
H.O.
If I apply Phong Material it works... At least that...
One more question: You wrote "Mouse support will come in the New Year". Is it already possible to detect which object (/mesh) in a Scene3D was clicked?
14 - Apr - 2015
miaorui
It seems that I dont have this head file : Qt3DQuick/quickwindow.h
what should I do?
Other includes are just fine
14 - Apr - 2015
Sean Harmer
It no longer exists as it was redundant. Please take a look at the examples in HEAD of the 5.5 branch to see how they are implemented now.
27 - Apr - 2015
Bramastyo Harimukti
What a great work on Qt3D! Thanks for making it true, especially with the assimp supported features. Anyway I have tried to implement the assimp and successfully loaded many different 3D formats. But the problem is that I couldn't able to load the textures correctly though I have tried to edit the sources of "Assimpparser" as well. Do you have any idea what could possibly the mistake that I have done here?
Best regards,
Bramastyo Harimukti
27 - Apr - 2015
Sean Harmer
Paul Lemire is working on a patch that does exactly that. It should appear on gerrit and be merged shortly.
Awesome! Thanks for your quick reply. Now it loads the textures very well! I have another question regarding how to run the applied animations inside the 3D file. When I used assimp_viewer such a feature is possible there. Is it also possible to do so with Qt 3D 2.0? Or is there any patch done regarding this task? Anyway I love this version of Qt3D a lot!
Best regards,
Bramastyo Harimukti
28 - Apr - 2015
Sean Harmer
Nothing in place as yet for this. One possibility is to have the assimp loader expose the sub meshes as a palette we can select from to then apply animations to. Skeletal animations are not planned until after the initial release, unless somebody wants to step up and implement them of course, in which case we will gladly take any help we can get.
30 - Apr - 2015
Bramastyo Harimukti
Thanks a lot Mr. Harmer for your kind answers and explanations. Is there any example done which expose the sub meshes as a palette to be animated so far? And I have another question about transparencies, is there any way to setup the transparent mode while rendering at the moment?
Best regards,
Bramastyo Harimukti
30 - Apr - 2015
Sean Harmer
No example yet as this will be a new feature that needs implementing. Patches welcome.
To use transparency you need a custom framegraph that turns on blending and sorts primitives from back to front for the transparent object pass.
15 - Jun - 2015
Bramastyo Harimukti
Hi Mr. Harmer,
I have another small question. Is it possible to replace the Objloader in QMesh with assimp? And is there any example to dynamically specify shaders with QML for models which are loaded through Assimp? It works with Mesh but not with SceneLoader. I am trying to implement this but have no idea how it works. Thanks a lot!
Best regards,
Bramastyo Harimukti
15 - Jun - 2015
Sean Harmer
Not as yet. We're investigating ways of selecting sub-objects loaded by assimp via the SceneLoader so that they can be rendered with custom materials etc.
28 - Jul - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
Thanks a lot for your reply. Yes I realize that we can't change the color or shader when we are loading a model with SceneLoader as we can do with Mesh (ObjLoader). Could you please tell me why this approach is not the same like what Mesh does? I realized that with the SceneLoader(AssimpParser) we are returning a QMesh pointer but in Mesh we are simply returning loaded Mesh into QMesh. Is this one of the reason behind?
Thank you so much for your time!
Best regards,
Bramastyo Harimukti
28 - Jul - 2015
Sean Harmer
We are researching in to how to get access to the constructed tree of elements. In fact Laszlo from The Qt Company pushed an example around this today. https://codereview.qt-project.org/#/c/122323/
31 - Aug - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
thanks for all of your answers here. Though I have one small question regarding the texture.
So basically I need to import the image and convert the format into "QImage::Format_RGBA8888_Premultiplied". And if I have a look into some sources and examples that the QAbstractTextureProvider requires QTextureImage for its texture image, how can I possibly insert the QImage to this QTextureImage? Since there is no possibility to convert the format into premultiplied alpha. Is there any example that has done this before?
I need to do this because I have to use a png image that has an alpha value as the texture.
Thanks a lot for your time!
BR,
Bramastyo Harimukti
31 - Aug - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
never mind my previous question. I have solved the problem :D
BR,
Bramastyo Harimukti Santoso
22 - May - 2015
Ramesh Y
Is Qt3D handling the devicePixelRatio()? On the mac, the viewport is clipped to the botttom left 1/4th area. All the samples shipped have the same issue. Would love to know how to fix this problem.
3 - Jun - 2015
Dave Anderson
I am not a professional software developer, rather I am an aerospace engineer. I want to use Qt as the central framework for a new autonomous systems simulation I am building, largely because of the excellent toolset offered by Qt3D. However, after downloading the Qt5.5 beta, I can get only a handful of the examples to work (nothing relying on exampleresources) and I am now growing very concerned about any further commitment to Qt. Should the examples be available and working right out of the box in the beta or am i commiting some newbie mistake?
9 - Jun - 2015
Sean Harmer
Hi Dave,
What platform is this on please? The examples are working here for me on Linux and OS X. I know there have been some relatively late changes made to the examples that use the assets so it's possible something got broken. Can you file a bug report at bugreports.qt.io please and we can take a look into this. Please be aware that Qt 5.5 ships with a technology preview of Qt3D so there will be gaps and broken pieces of functionality still. We aim for a stable release with Qt 5.6 at the end of this year.
9 - Jun - 2015
kang
How to draw custom dynamic per vertex data for c++ and qml?does this support for qml,? Thanks
12 - Jun - 2015
Sean Harmer
At present, by subclassing QAbstractMesh and providing a functor that provides your vertex data. This is on the short list for improving and extending in the next month or so.
11 - Jun - 2015
GHIAT houssem
Hi, i m new to qt3d world and i didn't use the qt3d 1.0, My question is really stupid but how to draw a simple line or point in the 3d space using qt3d?, thank you in advance.
12 - Jun - 2015
Sean Harmer
At present you will need to create a custom piece of geometry by subclassing QAbstractMesh. We will be adding more such standard pieces of geometry as time goes on and making it efficient to draw very large numbers of them via instancing (where the underlying GPU supports it). Contributions welcome.
12 - Jun - 2015
GHIAT Houssem
thank you for your response, i am working on an application in civil enginnering and i need to draw meshs based on nodes(points) and edges(lines) and have the capability to pick any node or edge to do further processing. from your response i understand that this kind of drawing will not be done efficiently on qt3d as it is now?
12 - Jun - 2015
Sean Harmer
It all depends upon how many buffers you put your points and lines into. It's perfectly possible to render many 10's or hundreds of thousands of vertices in one go form a single buffer. However, if you have many small buffers with a few points each this is the area where we need some improvements (which are planned and designed). We are looking to implement these in the next 1 to 2 months.
12 - Jun - 2015
GHIAT houssem
thank you for your quick response, one more question, is there an example or an article on how to subclass QAbstarctMesh for making custom piece of geometry ?.
15 - Jun - 2015
Sean Harmer
Take a look at the Qt3D sources, QSphere for e.g.
9 - Jul - 2015
Michel
You wrote “Mouse support will come in the New Year”.
So it is not possible to detect which object in a Scene3D was clicked?
20 - Jul - 2015
Jakub
Hi,
very helpfull tutorial.
But...
I have a question. Im working on Scene3D and Entities inside. Now, how to pick one of the loaded models (meshes/entities) on click on them?
I create MouseArea and recive x,y on click for now, but I can't find any function in Scene3D that can return entity on actual x,y.
31 - Aug - 2015
Bramstyo Harimukti
Hi
maybe you need to have a look into transformation component for that case. And try to insert the transformation component as the components of your entity together with your loaded mesh.
BR,
Bramastyo Harimukti
22 - Jul - 2015
Ram
Is there a to get Qt3D working with QWidget (or QOpenGLWidget)? I have seen suggestions on using QWidget::createWindowContainer but have been unable to get it to work. Any sample code would be really helpful. Ideally, I would want Qt3d to work directly with widgets without having to create QWindow.
23 - Aug - 2015
uauaua
Hi Ram,
i have the same Problem. I want also use OpenGL/Qt3d in Dialog-Window and run it in a Widget.
I have not any solution for These Problem. I found only the way over a new Window.
Do you have found a solution in the meantime?
30 - Aug - 2015
Sean Harmer
Create the QWindow and embed it into your widget hierarchy using QWidget::createWindowContainer().
28 - Jul - 2015
Lena
Hello, I'm currently exploring the Qt3D, especially the qml part and have tried most of the Qt3D qml examples.
However, I fail to combine Scene3D and a RenderGraph with multiple viewports.
What I want to achieve is a Qt Quick application with a 3D scene with four Viewports showing a little 3D world from different points of view on the one side of my appications screen
and another screen area containing Qt Quick elements like buttons, textfield etc. to interact with and show information about the 3D scene.
I tried to combine the examples 'multiviewport' and 'scene3d'.
When I add my custom 3D scene inside the multiviewport example, it works fine and I can watch my scene from four differen points of view with the viewports arranged in a grid.
However, when I try to embedd this 3D content in a Qt Quick application by putting the root Entity in a Scene3D element like it is done in the 'scene3d' example, my RenderGraph with four subviewports inside one main viewport is not rendered correctly and the four viewports are not displayed one besides each other in the main viewport, but one over another, all four filling the whole 3D screen area.
Can you give me a hint what I do wrong, or what is the rigth way to embed multiple views of the same 3D scene into a Qt Quick application?
Is the Scene3D element some kind of limited to simple render graphs or only one viewport at a time?
28 - Jul - 2015
Sean Harmer
That should work. It sounds like you've made a mistake adapting the framegraph to utilise multiple viewports. In fact the multiviewport example uses a Scene3D item so it must work.
29 - Jul - 2015
Lena
Thank your for your quick answer. I'm pleased to hear, that it should work to combine Scene3D and a multiviewport RenderGraph - however, I can't find my mistake.
First, the multiviewport example I got with my Qt 5.5 installation does not use a Scene3D item. (Is there another version of this example perhaps?)
In my multiviewport example project, I have a main.qml file with an Entity as root element, which contains a CameraLens Element and another Entity sceneRoot.
The sceneRoot Entity contains (amongst others) the multiviewport FrameGraph definition, four Entities for the cameras/viewports and an Entity with a SceneLoader - thats where I put my custom 3D world (Custom Qml file with root Entity, some Objects, some Materials..) instead.
Thats the only change I made in this example project.
And this works fine! I can see my animated scene in four viewports arranged in a grid.
Now I try to modify the scene3d example to embed my multiviewport graph in a Qt Quick application.
My scene3d example's main.qml file contains amongst others a Scene3D element containing an instance of a custom Entity AnimatedEntity.qml.
I added a MultiviewportEntity.qml file instead of AnimatedEntity.qml, where I put the whole content of the multiviewport example main.qml file - without changing anything in the multiviewport FrameGraph definition. (Of course, I also added the qml files defining my custom 3D world to the project)
Inside the Scene3D element I now add an instance of MultiviewportEntity.qml instead of AnimatedEntity.qml in the example code.
The result is, that all viewports are displayed one over/inside each other, each filling the whole Scene3D area.
But I didn't change anything in the FrameGraph definition of the multiviewport example but only copy pasted the whole multiviewport example's main.qml content into MultiviewportEntity.qml.
Seems that the problem is fixed. Running the same project in Qt Creator 5.6, everything works fine.
18 - Aug - 2015
YL
Hi,
I have tried to run the Qt3D example called "materials" and compiled it without a problem. Then when I run the program, it couldn't open a single .obj or .webp.
(Qt3D.Renderer.Jobs: virtual Qt3D::QMeshDataPtr Qt3D::MeshFunctor::operator()() OBJ load failure for: ":/assets/chest/Chest.obj"
Failed to load image : ":/assets/textures/pattern_09/diffuse.webp"
Texture data is null, texture data failed to load)
I am pretty sure this can be traced back to QMesh.setSource() and QTextureImage.setSource() but I don't where to go from here on.
This is probably a very rookie mistake. Thanks in advance for your help.
YL
21 - Aug - 2015
YL
I actually solved the problem now. Very rookie mistake...
With apologies,YL
30 - Aug - 2015
Sean Harmer
Out of interest, what was the issue?
29 - Jun - 2017
Shinu
I'm also facing the same issue. How you fixed this?
27 - Nov - 2015
geaggle
Hi YL,
i get the same message. How did you solve the problem ? May you could post your code.Thanks in advance for your help.
geaggle
24 - Sept - 2015
nonamepalmer
Hi,
please help me ! How can i Blender created file 3ds or obj with a Texturefile png.
thanks
nonamepalmer
8 - Oct - 2015
Toye onikoyi
Hi all,
I am using qt 3d and having trouble importing and displaying my mesh from blender whether it is a obj. file or .3ds file. I am using qml, and from the example code I cant seem to create my own meshes. In the example for main.cpp where does the window.h file come from is it important to display 3d meshes?
I'm using Qt quick-Qml with Qt version Qt 5.9, and I want to load a detailed 3d-model (from collada file) using sceneLoader (assimp). then dealing with separated objects (subparts of this model).
e.g: loading a "car.dae" model then handels the left front wheel.
I managed to load the model but I'm getting a runtime error when I'm trying to accsess the subparts (entities) inside the model. I have tried "SceneHelper" from assimp and tyhe methods "entity(string name)" and "entitynames()" from SceneLoader.
The run error comes with the a debug message "ASSERT: "entities.size() == 1" in file io\qsceneloader.cpp, line 260".
Can you please informe me if this feature )accessing the sub parts) is supported in Qt3D (Qt version Qt5.9) or not.
with best regards
Sean Harmer
Managing Director KDAB UK
Dr Sean Harmer is a senior software engineer at KDAB where he heads up our UK office and also leads the 3D R&D team. He has been developing with C++ and Qt since 1998 and is Qt 3D Maintainer and lead developer in the Qt Project. Sean has broad experience and a keen interest in scientific visualization and animation in OpenGL and Qt. He holds a PhD in Astrophysics along with a Masters in Mathematics and Astrophysics.
67 Comments
8 - Jan - 2015
Philip
Awesome work! Way better than Qt3D 1.0. Keep up the hard work. I can't wait until the next article.
8 - Jan - 2015
Sean Harmer
Thank you. Still plenty to do and rough edges to polish but we're getting there I think.
8 - Jan - 2015
Philip
I downloaded the source and ran the examples. They all seemed to work. Many of them crashed at on closing them.
On another note, does a3d support anti-aliasing out of the box? Does the frame graph support MSAA? I'm assuming that I could easily implement SSAA or FXAA in the frame graph?
8 - Jan - 2015
Sean Harmer
Yeah, known issue. I was hoping to resolve it over Xmas but ended up tracking down an issue with qdoc. I have some time assigned this month and that bug is high on my list.
8 - Jan - 2015
Sean Harmer
We will offer a property for enabling MSAA. Yes, supporting SSAA and FXAA will be trivial via the framegraph and a custom post-proc shader.
8 - Jan - 2015
Philip
Sweet! This is definitely an exciting technology!
9 - Jan - 2015
Stephane
This is really exciting, also the component approach i like a lot.
all the best for Qt3D !
Can't wait for next article :)
12 - Jan - 2015
Jasem Mutlaq
Wow, this is very exciting indeed and I am glad Qt3D is coming back stronger than ever! Excellent job KDAB!
13 - Jan - 2015
Cera
Great work guys.
17 - Jan - 2015
jiangcaiyang
Nice work! I want to contribute my code and technology to KADB on Qt 3D work! Currently I have Android, iOS and Window Phone devices available for testing Qt 3D, in addition, I have a few code want to live happy with Qt 3D. So I want to know is it possible to write a custom Model format parser with Qt 3D? Is it to write under Assimp library or under one of Qt 3D's interface. This format support skeleton animation but the animation stays in another animation file. How to join KDAB to contribute my code to Qt 3D?
17 - Jan - 2015
Sean Harmer
Thank you! You are most welcome to join us improving Qt3D. We are developing Qt3D in the open as part of the overall Qt Project. You can usually find us hanging out on #qt-3d channel on freenode. Alternatively you can reach us via the development@qt-project.org mailing list.
Any help in making Qt3D work on Android, iOS or Windows Phone would be most welcome indeed. We think the necessary abstractions are in place but I'm sure there will be some build time and runtime issues to resolve.
We would also love to help you get your skeletal animation format supported for Qt3D 2.1. It's something we have on the roadmap but we have yet to start development of a skeletal animation aspect so this would be a great area for you to dive into. Qt3D has hooks for loading custom mesh formats but we do not yet have anything to support skeletal animation. I don't think this should be too hard to add in however.
Hope to see you online shortly!
21 - Jan - 2015
jiangcaiyang
Thank you for your reply! These time in addition to work with my project currently, I want to look deep into the awesome Qt 3D. Recently I want to download Qt 5.5 together with Qt 3D and try to learn some concept on Qt 3D. I'd be happy to go forward with KDAB and Qt contributors!
1 - Apr - 2015
H.O.
Thanks for the great work. For my current project I need the integration of QtQuick 2 and Qt3D for UI implementation as you already mentioned above. Do you have an example for that? The clues regarding QQuickFramebufferObject and QQuickRenderControl are not helpful, cause I'm totally new to QtQuick and Qt3D. Any help would be great! Thanks in advance!
1 - Apr - 2015
Sean Harmer
Wrap your 3D world in a Scene3D{} element and use this like any other Qt Quick 2 item. Take a look at the Scene3D example that ships with Qt3D.
1 - Apr - 2015
H.O.
Thanks, that was really quick! Sadly I still did not get it working cause now in the combination of Qt3D and QtQuick I get a message which says: "GLSL 1.50 is not supported. Supported versions are: 1.10, 1.20, 1.30, 1.00 ES, and 3.00 ES" Somehow he tries to compile a fragment shader. This happens only if I try to load files exported from Blender (*.obj). The above mentioned example works well.
1 - Apr - 2015
Sean Harmer
Seems you are trying to use a GLSL shader in one of the materials that is assuming OpenGL 3.2 but your system doesn't have that. Can you track down which shader is giving that error?
1 - Apr - 2015
H.O.
The application output is
It happens when I apply no special material at all and even as well when I apply the WireframeMaterial from your example. Thanks a lot for your help!
1 - Apr - 2015
Sean Harmer
The wireframe material is expected to require OpenGL 3, but the default material should work anywhere. Please file a bug at bugreports.qt.io for this with a small test case and a description of your setup.
1 - Apr - 2015
H.O.
If I apply Phong Material it works... At least that...
1 - Apr - 2015
H.O.
Opened a bugreport. Here is the link: https://bugreports.qt.io/browse/QTBUG-45366
10 - Apr - 2015
H.O.
One more question: You wrote "Mouse support will come in the New Year". Is it already possible to detect which object (/mesh) in a Scene3D was clicked?
14 - Apr - 2015
miaorui
It seems that I dont have this head file : Qt3DQuick/quickwindow.h what should I do? Other includes are just fine
14 - Apr - 2015
Sean Harmer
It no longer exists as it was redundant. Please take a look at the examples in HEAD of the 5.5 branch to see how they are implemented now.
27 - Apr - 2015
Bramastyo Harimukti
What a great work on Qt3D! Thanks for making it true, especially with the assimp supported features. Anyway I have tried to implement the assimp and successfully loaded many different 3D formats. But the problem is that I couldn't able to load the textures correctly though I have tried to edit the sources of "Assimpparser" as well. Do you have any idea what could possibly the mistake that I have done here?
Best regards, Bramastyo Harimukti
27 - Apr - 2015
Sean Harmer
Paul Lemire is working on a patch that does exactly that. It should appear on gerrit and be merged shortly.
27 - Apr - 2015
Sean Harmer
And here's the patch if you want to try it https://codereview.qt-project.org/#/c/111317/3
28 - Apr - 2015
Bramastyo Harimukti
Awesome! Thanks for your quick reply. Now it loads the textures very well! I have another question regarding how to run the applied animations inside the 3D file. When I used assimp_viewer such a feature is possible there. Is it also possible to do so with Qt 3D 2.0? Or is there any patch done regarding this task? Anyway I love this version of Qt3D a lot!
Best regards, Bramastyo Harimukti
28 - Apr - 2015
Sean Harmer
Nothing in place as yet for this. One possibility is to have the assimp loader expose the sub meshes as a palette we can select from to then apply animations to. Skeletal animations are not planned until after the initial release, unless somebody wants to step up and implement them of course, in which case we will gladly take any help we can get.
30 - Apr - 2015
Bramastyo Harimukti
Thanks a lot Mr. Harmer for your kind answers and explanations. Is there any example done which expose the sub meshes as a palette to be animated so far? And I have another question about transparencies, is there any way to setup the transparent mode while rendering at the moment?
Best regards, Bramastyo Harimukti
30 - Apr - 2015
Sean Harmer
No example yet as this will be a new feature that needs implementing. Patches welcome.
To use transparency you need a custom framegraph that turns on blending and sorts primitives from back to front for the transparent object pass.
15 - Jun - 2015
Bramastyo Harimukti
Hi Mr. Harmer,
I have another small question. Is it possible to replace the Objloader in QMesh with assimp? And is there any example to dynamically specify shaders with QML for models which are loaded through Assimp? It works with Mesh but not with SceneLoader. I am trying to implement this but have no idea how it works. Thanks a lot!
Best regards, Bramastyo Harimukti
15 - Jun - 2015
Sean Harmer
Not as yet. We're investigating ways of selecting sub-objects loaded by assimp via the SceneLoader so that they can be rendered with custom materials etc.
28 - Jul - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
Thanks a lot for your reply. Yes I realize that we can't change the color or shader when we are loading a model with SceneLoader as we can do with Mesh (ObjLoader). Could you please tell me why this approach is not the same like what Mesh does? I realized that with the SceneLoader(AssimpParser) we are returning a QMesh pointer but in Mesh we are simply returning loaded Mesh into QMesh. Is this one of the reason behind?
Thank you so much for your time!
Best regards, Bramastyo Harimukti
28 - Jul - 2015
Sean Harmer
We are researching in to how to get access to the constructed tree of elements. In fact Laszlo from The Qt Company pushed an example around this today. https://codereview.qt-project.org/#/c/122323/
31 - Aug - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
thanks for all of your answers here. Though I have one small question regarding the texture.
So basically I need to import the image and convert the format into "QImage::Format_RGBA8888_Premultiplied". And if I have a look into some sources and examples that the QAbstractTextureProvider requires QTextureImage for its texture image, how can I possibly insert the QImage to this QTextureImage? Since there is no possibility to convert the format into premultiplied alpha. Is there any example that has done this before?
I need to do this because I have to use a png image that has an alpha value as the texture.
Thanks a lot for your time!
BR, Bramastyo Harimukti
31 - Aug - 2015
Bramstyo Harimukti
Hi Mr. Harmer,
never mind my previous question. I have solved the problem :D
BR, Bramastyo Harimukti Santoso
22 - May - 2015
Ramesh Y
Is Qt3D handling the devicePixelRatio()? On the mac, the viewport is clipped to the botttom left 1/4th area. All the samples shipped have the same issue. Would love to know how to fix this problem.
3 - Jun - 2015
Dave Anderson
I am not a professional software developer, rather I am an aerospace engineer. I want to use Qt as the central framework for a new autonomous systems simulation I am building, largely because of the excellent toolset offered by Qt3D. However, after downloading the Qt5.5 beta, I can get only a handful of the examples to work (nothing relying on exampleresources) and I am now growing very concerned about any further commitment to Qt. Should the examples be available and working right out of the box in the beta or am i commiting some newbie mistake?
9 - Jun - 2015
Sean Harmer
Hi Dave,
What platform is this on please? The examples are working here for me on Linux and OS X. I know there have been some relatively late changes made to the examples that use the assets so it's possible something got broken. Can you file a bug report at bugreports.qt.io please and we can take a look into this. Please be aware that Qt 5.5 ships with a technology preview of Qt3D so there will be gaps and broken pieces of functionality still. We aim for a stable release with Qt 5.6 at the end of this year.
9 - Jun - 2015
kang
How to draw custom dynamic per vertex data for c++ and qml?does this support for qml,? Thanks
12 - Jun - 2015
Sean Harmer
At present, by subclassing QAbstractMesh and providing a functor that provides your vertex data. This is on the short list for improving and extending in the next month or so.
11 - Jun - 2015
GHIAT houssem
Hi, i m new to qt3d world and i didn't use the qt3d 1.0, My question is really stupid but how to draw a simple line or point in the 3d space using qt3d?, thank you in advance.
12 - Jun - 2015
Sean Harmer
At present you will need to create a custom piece of geometry by subclassing QAbstractMesh. We will be adding more such standard pieces of geometry as time goes on and making it efficient to draw very large numbers of them via instancing (where the underlying GPU supports it). Contributions welcome.
12 - Jun - 2015
GHIAT Houssem
thank you for your response, i am working on an application in civil enginnering and i need to draw meshs based on nodes(points) and edges(lines) and have the capability to pick any node or edge to do further processing. from your response i understand that this kind of drawing will not be done efficiently on qt3d as it is now?
12 - Jun - 2015
Sean Harmer
It all depends upon how many buffers you put your points and lines into. It's perfectly possible to render many 10's or hundreds of thousands of vertices in one go form a single buffer. However, if you have many small buffers with a few points each this is the area where we need some improvements (which are planned and designed). We are looking to implement these in the next 1 to 2 months.
12 - Jun - 2015
GHIAT houssem
thank you for your quick response, one more question, is there an example or an article on how to subclass QAbstarctMesh for making custom piece of geometry ?.
15 - Jun - 2015
Sean Harmer
Take a look at the Qt3D sources, QSphere for e.g.
9 - Jul - 2015
Michel
You wrote “Mouse support will come in the New Year”.
So it is not possible to detect which object in a Scene3D was clicked?
20 - Jul - 2015
Jakub
Hi, very helpfull tutorial.
But... I have a question. Im working on Scene3D and Entities inside. Now, how to pick one of the loaded models (meshes/entities) on click on them? I create MouseArea and recive x,y on click for now, but I can't find any function in Scene3D that can return entity on actual x,y.
31 - Aug - 2015
Bramstyo Harimukti
Hi
maybe you need to have a look into transformation component for that case. And try to insert the transformation component as the components of your entity together with your loaded mesh.
BR, Bramastyo Harimukti
22 - Jul - 2015
Ram
Is there a to get Qt3D working with QWidget (or QOpenGLWidget)? I have seen suggestions on using QWidget::createWindowContainer but have been unable to get it to work. Any sample code would be really helpful. Ideally, I would want Qt3d to work directly with widgets without having to create QWindow.
23 - Aug - 2015
uauaua
Hi Ram, i have the same Problem. I want also use OpenGL/Qt3d in Dialog-Window and run it in a Widget.
I have not any solution for These Problem. I found only the way over a new Window.
Do you have found a solution in the meantime?
30 - Aug - 2015
Sean Harmer
Create the QWindow and embed it into your widget hierarchy using QWidget::createWindowContainer().
28 - Jul - 2015
Lena
Hello, I'm currently exploring the Qt3D, especially the qml part and have tried most of the Qt3D qml examples. However, I fail to combine Scene3D and a RenderGraph with multiple viewports. What I want to achieve is a Qt Quick application with a 3D scene with four Viewports showing a little 3D world from different points of view on the one side of my appications screen and another screen area containing Qt Quick elements like buttons, textfield etc. to interact with and show information about the 3D scene. I tried to combine the examples 'multiviewport' and 'scene3d'. When I add my custom 3D scene inside the multiviewport example, it works fine and I can watch my scene from four differen points of view with the viewports arranged in a grid. However, when I try to embedd this 3D content in a Qt Quick application by putting the root Entity in a Scene3D element like it is done in the 'scene3d' example, my RenderGraph with four subviewports inside one main viewport is not rendered correctly and the four viewports are not displayed one besides each other in the main viewport, but one over another, all four filling the whole 3D screen area. Can you give me a hint what I do wrong, or what is the rigth way to embed multiple views of the same 3D scene into a Qt Quick application? Is the Scene3D element some kind of limited to simple render graphs or only one viewport at a time?
28 - Jul - 2015
Sean Harmer
That should work. It sounds like you've made a mistake adapting the framegraph to utilise multiple viewports. In fact the multiviewport example uses a Scene3D item so it must work.
29 - Jul - 2015
Lena
Thank your for your quick answer. I'm pleased to hear, that it should work to combine Scene3D and a multiviewport RenderGraph - however, I can't find my mistake. First, the multiviewport example I got with my Qt 5.5 installation does not use a Scene3D item. (Is there another version of this example perhaps?) In my multiviewport example project, I have a main.qml file with an Entity as root element, which contains a CameraLens Element and another Entity sceneRoot. The sceneRoot Entity contains (amongst others) the multiviewport FrameGraph definition, four Entities for the cameras/viewports and an Entity with a SceneLoader - thats where I put my custom 3D world (Custom Qml file with root Entity, some Objects, some Materials..) instead. Thats the only change I made in this example project. And this works fine! I can see my animated scene in four viewports arranged in a grid. Now I try to modify the scene3d example to embed my multiviewport graph in a Qt Quick application. My scene3d example's main.qml file contains amongst others a Scene3D element containing an instance of a custom Entity AnimatedEntity.qml. I added a MultiviewportEntity.qml file instead of AnimatedEntity.qml, where I put the whole content of the multiviewport example main.qml file - without changing anything in the multiviewport FrameGraph definition. (Of course, I also added the qml files defining my custom 3D world to the project) Inside the Scene3D element I now add an instance of MultiviewportEntity.qml instead of AnimatedEntity.qml in the example code. The result is, that all viewports are displayed one over/inside each other, each filling the whole Scene3D area. But I didn't change anything in the FrameGraph definition of the multiviewport example but only copy pasted the whole multiviewport example's main.qml content into MultiviewportEntity.qml.
29 - Jul - 2015
Sean Harmer
Sorry it's impossible to see where the mistake is without seeing the code. For reference the multiviewport using a Scene3D element is here http://code.qt.io/cgit/qt/qt3d.git/tree/examples/qt3d/multiviewport/main.qml. Please feel free to drop by the #qt-3d channel on irc if you need help.
6 - Oct - 2015
Lena
Seems that the problem is fixed. Running the same project in Qt Creator 5.6, everything works fine.
18 - Aug - 2015
YL
Hi, I have tried to run the Qt3D example called "materials" and compiled it without a problem. Then when I run the program, it couldn't open a single .obj or .webp.
I am pretty sure this can be traced back to QMesh.setSource() and QTextureImage.setSource() but I don't where to go from here on. This is probably a very rookie mistake. Thanks in advance for your help.
YL
21 - Aug - 2015
YL
I actually solved the problem now. Very rookie mistake...
With apologies,YL
30 - Aug - 2015
Sean Harmer
Out of interest, what was the issue?
29 - Jun - 2017
Shinu
I'm also facing the same issue. How you fixed this?
27 - Nov - 2015
geaggle
Hi YL, i get the same message. How did you solve the problem ? May you could post your code.Thanks in advance for your help. geaggle
24 - Sept - 2015
nonamepalmer
Hi, please help me ! How can i Blender created file 3ds or obj with a Texturefile png. thanks nonamepalmer
8 - Oct - 2015
Toye onikoyi
Hi all,
I am using qt 3d and having trouble importing and displaying my mesh from blender whether it is a obj. file or .3ds file. I am using qml, and from the example code I cant seem to create my own meshes. In the example for main.cpp where does the window.h file come from is it important to display 3d meshes?
12 - Nov - 2015
Khanh
HI Sean Harmer, Can you help me answer this question about drawing a massive amount of Vertex Buffer from BVH tree nodes using QT3D 2.0. https://forum.qt.io/topic/60579/draw-a-massive-amount-of-gl-vertex-buffer-in-one-mesh-using-qt3d
7 - Jun - 2017
Issam
Hello,
I'm using Qt quick-Qml with Qt version Qt 5.9, and I want to load a detailed 3d-model (from collada file) using sceneLoader (assimp). then dealing with separated objects (subparts of this model). e.g: loading a "car.dae" model then handels the left front wheel. I managed to load the model but I'm getting a runtime error when I'm trying to accsess the subparts (entities) inside the model. I have tried "SceneHelper" from assimp and tyhe methods "entity(string name)" and "entitynames()" from SceneLoader.
The run error comes with the a debug message "ASSERT: "entities.size() == 1" in file io\qsceneloader.cpp, line 260".
Can you please informe me if this feature )accessing the sub parts) is supported in Qt3D (Qt version Qt5.9) or not.
with best regards