Greetings from Fosdem13

February 4th, 2013

UPDATE: I published this one day too late, but here it is anyway:)

I’m writing this blog post from Fosdem. It’s my last day here and it feels that I’m already waiting for the next Fosdem. I must say that it’s amazing what volunteers can achieve. Thousands of developers, hundreds of presentations and a lot of beer.  Great work I must say!

I actually came to Fosdem to keep a presentation about QML mobile application development and I demoed how to abstract platform dependencies away so that it’s easier to port your mobile app to different platforms. The showcase part was demoed on Sailfish OS. I think the feedback I got from the presentation was very nice. So thank you for that!

I didn’t come to Fosdem alone. I came with other people like Carsten Munk (@stskeeps), David Greaves (@lbt) from Mer project, Marko Saukko(@sage), Carol Chen (@cybette) and Iekky Pylkkä (@iekku) from Jolla. David and Marko are also having talks here. Marko will talk about Porting Nemo Mobile and Mer to a new HW and David will be talking about How do we make “Qt on Mer” the solution of choise for device vendors.

So if you’re still here and you’re interested in Mer or Nemo Mobile, go to see these presentations.

Btw, the public transportation is really crowded here:)

20130203-094741
I think this is enough about blogging this time, but I just want to thank (again) all the voluteers and of course other people coming to here. What a great event!

 

Deploying shaders for view transitions on Qt5 / QtQuick 2.0

August 26th, 2012

I’ve been playing with QML quite a long time, even though it’s a young technology. I bet, I’m not the only one who has noticed that when building an application with QML, you may end up having a bunch of views and then you should figure you a way to navigate between them.

You can of course create all the views in the beginning and then switch between them based on user’s interaction. This may lead you to the situation where your app eats memory and your “Main.qml” is rather large. Another way is to build your own framework which provides an infrastructure for creating and displaying those views. The third way would be to use a ready-made framework such as Qt-Components. The third way, may not be always an option because it may work only on certain platforms, therefore you’ll end up building something of your own.

I decided to give a try and build something of my own. I call it “d-touch” framework. I had the following list in my mind how the framework should work:

  1. Transitions between views must be dynamic i.e. I want to be able to change from slide transition to something else without touching a code at all.
  2. I don’t want to create all the views in the beginning in my main. Instead I want to load them dynamically on demand.
The first requirement was solved using shaders. To be more precise, I use only fragment shaders at the moment. This lead me to a solution that I don’t need to define “positions” for views and then do transitions e.g. from (x1,y2) to (x2,y2) coordinates. Instead, I just make them to be in a “view stack” and actual transition has been implemented using Qt5′s ShaderEffect element.
The second requirement is solved by providing functionality (functions) for creating views dynamically. View management is handled fully by d-touch framework. Views just define, what QML files needs to be opened or closed and the framework handles the rest.
Here’s a short video where I demonstrate how shader based transitions work and all the views are created only when needed.

Read the rest of this entry »

I’m looking for a new Job!

August 20th, 2012

Things ain’t go always like you plan and therefore I’m starting to look for a new job. If you have read my blog, I’m pretty sure that you know I like Qt. So here’s my wish list what I’d like to do and what I’ve done:

  • I like to use Qt and Linux / Mac
  • I’m a ScrumMaster and I like scrum, so I like working in teams
  • I’m used to of multinational and distributed environments
  • Job should be in Finland  so hear me Jolla, Digia, Futurice, etc:)
  • I can keep Qt / QML trainings too
  • I like people, so I’m used to of working near to clients
  • I have worked both on mobile (Nokia N9) and on industrial side
  • I’ve released few apps to iOS side too
QML Portfolio
(update) I added my QML portfolio here too. It doesn’t include all the stuff, but the coolest ones. The last three videos are stuff that I’ve done for my previous employer.

If you are interested in to hire me, you can download my CV below or send me email directly to marko(dot)a(dot)mattila(at)gmail(dot)com. Oh yes, and I could start my new job (most likely) in the beginning of September.

Marko-Mattila-CV

Qt5: New signal and slot syntax

May 17th, 2012

I thought, that I should write about this topic, because it’s time to start my self-education project again and see how I can take new features of Qt in use. I’m not sure how useful this blog post is because there already is a nice wiki page available about the same topic on qt-project.org. But for those, who haven’t read the wiki page, this might be a bit shock – Yes, in Qt5 there is a new syntax for connecting signals and slots!

Don’t worry, your old code (Qt 4.x) doesn’t break and Trolls will continue the support of the old, string-based connection. So what’s new in the new signal-slot syntax then? Basically you can connect signals and slots using the following style shown in by the example below. Note that you still have to have Q_OBJECT macro defined in a class, which introduces signals or slots.

connect(sender, &Sender::valueChanged, receiver, &Receiver::updateValue );

Instead of using SIGNAL() and SLOT() macros, you can now also use C++ function pointers to connect signals and slots. In Qt5, you can connect signals to any member function of a class  i.e. they don’t need to be slots. Note that in the end, Qt slots are only class’ member functions. The “slots” keyword is only an empty define and used only by MOC (Meta Object Compiler) when parsing headers.

Read the rest of this entry »