Congrats, let's go!
Right, I need to summarize how Quinn draws at the moment.
Quinn is responsible for drawing your windows on the screen,
and then occasionally, we draw effects on top.
And the way it currently works, is it's a simple path to draw all your windows,
and then throughout this, effects have various hooks where you just randomly
throw OpenGL Yale calls in the middle of Quinn trying to do its main business.
And I opened Yale codes quite long and old, so this is code to draw a circle,
not lots of circles, a circle.
Don't expect you to read it. It's a lot of code.
And I wrote this slide about knowing Martin was going to be here.
The result isn't very good.
It looks like it was written 10 years ago.
Fair enough, it was.
But the problem is, the Quinn developers, the core developers,
want to make the core even lower.
They really need a fine-grained control of everything we're doing,
changing which OpenGL call based on which drive you're using and what day of
the week it is, and drawing onto different planes, and having absolute control
of everything, knowing how long everything's going to take.
And they want to have this really light scene graph with very simple rectangles,
and long term also have a path to Vulkan.
And I say long term, there's work in progress right now.
And you can't have a path to Vulkan if you have loads of code throwing OpenGL calls at your screen.
Now, as a not hardcore dev, that's not what I want.
I want a very lightweight, simple API where I can draw in, load an image,
load a texture, draw some text, which is really difficult in low-level OpenGL,
and I definitely do not want to write another path for Vulkan.
It would mean rewriting everything from scratch.
So if we're going to do that, we need to look for a path forward that satisfies
both of those sets of requirements which are quite competing.
So the solution is to have two solutions.
A low-level quinn goes lower, and a high-level quinn where we need a high FX
goes higher, making use of Qt Quick.
So your Qt Quick code renders into a texture, into an off-screen buffer,
which the low-level code just sees as a rectangle, doesn't care what it is.
And if the high-level code wants to render a window or a whole desktop,
it just sees a regular Qt Quick item and doesn't care where that content comes from.
And the main change was making all this happen really, really fast with shared
OpenGL context, we can make all of that happen.
So it benefits. We saw about 20 lines of code to draw a rectangle.
Cute, quick, really easy. And also the designers can come in along.
People who don't know any C++ can come in along and add a color,
which actually I've forgotten.
So it's really readable code. It's really easy to edit, maintain, which is what we want.
And we get features like anti-aliasing for free.
So it looks like a nice circle, Martin.
But we also get interactivity really easy.
So we had this overview effect in the past where it zoomed out and it saw all
your windows, but doing a drag and drop or clicking a window and dragging it
into another desktop, that was a lot of painful code.
And sometimes we didn't have all of this code.
We can start searching and get krunner results and that's really easy.
All sorts of drag and drop and sliding and swiping.
Not very difficult code now.
And QQuick 3D is amazing and it's relatively easy to use.
So we added a cube back obviously because everybody loves a cube but I'll go for an example.
We had that effect before where you click a mouse and you get a little circle.
Why not a full 3D hand?
And before I exported this to a PDF, this was a lot more exciting.
So could you just pretend this is whizzing around with a vector animation on
your rotation? Just imagine that.
But it's not even very difficult code with Qt Quick.
You get a model, you run this magic command called balsam, and then you've got
your model and you can just throw it in there.
And you've even got all sorts of things for 3D.
And obviously, we should throw more particles at things because particles are
awesome, especially 3D particles.
So, we want to rewrite a lot of our effects, and that opens it up to everybody.
If you see any Quinn effect code that is doing drawing, which is the part we
want to really move over to Qt Quick, grab it.
It's quite a good task to get involved in Quinn, if you're interested.
Or do cool stuff with 3D and particles. But get involved.
That's the end.
Yeah it's lunchtime next i'm not gonna keep you,
talk for five minutes more you have the time any quick questions,
let's give the people time to prepare lunch,
Not really a question, but just a comment. So declarative QML effects is something
I dreamed about something like 10 years ago,
and I had concept of how to do it, but the technology was just not there. So I really love it.
Okay we have another quick one please is this
on i just wanted to mention uh something you didn't mention in your slide but
for the current c++ effects a lot of them also have a software path so this
is really nice instead of the separate open gl and software path now it can
all be through qt quick and that's quite a bit of complexity we could get rid of yeah so what
We've only got two paths, it was going to go up to three, now we've gone down to one.