Saturday, February 18, 2012

The Shift Towards Javascript

After much debate we've decided to abandon the Qt interface for an html5 javascript based interface. There were many reasons for moving in this direction, but the main ones dealt with mobile/web-support and faster development time. Qt does have some third-party support for buidling Qt apps on Android, but the interface would have to change to fit the app. Qt itself is a terrific platform with its meta-object system sitting on top of C++ with all the neat things like signals and slots and I would highly recommend checking it out for any future desktop applications.  But, the platform has alot more stuff than we need for this project since it is mainly based on doing graphics on a canvas. We don't require any really complex GUI widgets or anything of that sort, just one big canvas to render things on. Qt has a pretty good scene-graph system exactly for this, but there were many hurdles and loops through jump through just to do simple graphical actions and to interact with the rest of the gui. Development time on this system would have taken a lot longer than using a simpler platform. We also hope to turn this into a multi-user proofing system in the long run, either through the web or through some tablet interface and Qt would not extend easily to meet these needs in the future.

So we decided to go to a javascript based system that could work in any browser. This entails heavy cross-platform support and the multi-user system comes in with ease just by making the application a web app. Although there will be a big performance gap fromt Qt, this system will take much less time to develop and optimize. We also have to create very efficient algorithms and data structures for doing the proof process, but this is just more fun stuff to work on! After much searching and testing of different html5 frameworks and libraries I found one thats super-fast and very stable with a great API. Raphael.js will be the scene graph framework we will by using for the project. It works on both desktop and mobile browsers and is supported more or less across the board due to using SVGs instead of the html5 canvas. After just a couple hours of relearning javascript and picking up Raphael's api I've made a good early base for the proof system!

No comments:

Post a Comment