Saturday, 20 June 2009

Update and Exciting Features

Right so I thought it was about time to give a bit of an update on what I have been working on so far for my GSoC project. I have done some really interesting stuff with a lot of ground yet to cover so I'll try to keep it brief ( and I hope to update you all more frequently ).

If you have a look at my last post you can see the big goals that I have created for myself, which is a definite positive as I believe you can never aim high enough! The first of these goals is what i called the Annotation Rendering Framework, which has proved to be a challenge. The Idea of the rendering framework was to provide similar functionality to the QGraphicsView, QGraphicsScene and QGraphicsItem classes in the Qt Gui Module. And believe me, thats a hard act to follow! The main feature from the Qt classes that I wanted to recreate is the ability to "Click and Drag" items around the interface of marble, which is made difficult by the fact that marble is not a 2D surface and hit tests get a little bit more complicated.

Thankfully I have the opportunity to stand on the shoulders of giants to get all of this working. The Marble developers have implemented a lot of the necessary functionality to get my stuff off the ground an its my job to extend this and integrate it all in a useful way. So without further ado I have a small video to present you with showing a little bit of my work.

The next step is to get nice little pop-up showing the details of each annotation, be it text, video or audio. This hopefully shouldn't take very long as I have already done a few experiments to do with Geo-Located QWidgets so watch this space!


David Palacio said...

You should use the GV framework. QGS for the annotations and use the paint bacground function to draw the classic Marble.

Gopala Krishna said...

Wow! Nice work..

I guess you can still use QGV quite easily as an overlay.

Amarok people have infact designed a PopupDropper overlay system for drag and drop which overlays a transparent QGView on desired widget.

The trick they have used is

QGraphicsView *overlay = createViewWithItems();
QPalette p = overlay->palette();
p.setColor(QPalette::Window, QColor(r, g, b, 0 /*alpha*/));

overlay->move(x, y);

Tackat said...

David, Gopala:

No, sorry, using GraphicsView here directly isn't quite an option.

Marble has support e.g. for spherical projections and mostly deals with geographical coordinates.
These have a behaviour that is completely different from the x,y-semi-z approach that QGraphicsView has got (with the dateline, North/Southpole Singularity etc. .

Also the QGraphicsView API currently is suggestive in a way to use certain methods in the API which would decrease performance and would mislead people into doing things which they are not supposed to and which don't work with geographical coordinates in different projections.

Right now we are trying to do the whole class design and API as much QGraphicsView-like as possible. If it should turn out later on that QGraphicsView becomes an option to use in some way it should then be easy to switch.

Gopala Krishna said...

That explains it.. Thanks :)

real_ate said...

Wow! I didn't even know I had comments! Thank you Tackat for clearing up the QGraphicsView issue.
David, Gopala : Trust me, I would love to be using the QGraphicsView Stuff directly! I even came up with a big plan as to how that would be the *right* way to do it, I was so certain that this was the major theme of my first GSoC proposal. Too bad! ;)