SlideShare a Scribd company logo
1 of 29
Flickr Browser - Gazr
      Blanton Black
Motivation



• Visual Experience
• Performance
Motivation


• Visual Experience
 • Like Cover Flow
 • Fluid animation of large photosets
• Speed
Motivation

• Visual Experience
• Speed
 • Fast browsing (view more at once)
 • Heavy caching
 • Standalone Application
Platform

• Java
• Qt Jambi
 • Asynchronous APIs
• OpenGL
 • 3D animation
Photo Organization


• User
 • Collections (Nested)
   • Sets
     • Photos
Interface
Kinetic Scrolling


• Bézier curve
• Velocity control
• Movement triggers sound effect
Kinetic Scrolling
• Bézier curve
  • Smoothly
    interpolated from
    0 to 1

  • 3-dimensional
    cooridinates

• Velocity control
• Movement triggers
  sound effect
Kinetic Scrolling
• Bézier curve
  • Smoothly
    interpolated from
    0 to 1

  • 3-dimensional
    cooridinates

• Velocity control
• Movement triggers
  sound effect
Kinetic Scrolling

• Bézier curve
• Velocity control
  • Drag to accelerate
  • Click and hold to brake
• Movement triggers sound effect
Kinetic Scrolling


• Bézier curve
• Velocity control
• Movement triggers sound effect
  • Custom made
Kinetic Scrolling


• Bézier curve
• Velocity control
• Movement triggers sound effect
  • Custom made
Design
QObject                      QWidget




      QMainWindow                   QGLWidget

                                                                           Vector3
                                                             +x
          Gazr                            Flowr              +y
Attribute                     -gl: GL                        +z
Attribute                     -glu: GLU                      +plus(v: Vector3): Vector3
slots                         -ctrlPoints: List<Vector3>     +times(v: double): Vector3
on_flowr_photoClicked(photo)   -velocity: double              lerp(a: Vector3, b: Vector3): Vector3
                                                               *
                              -sound: MediaObject
                              signals
                              +photoClicked<Photo>       1
                              +Flowr()
                              +setPhotos()
                              -preDraw()
                              -drawCurve()
                              -drawImages()
                              events
                              -timerEvent()
                              -initializeGL()
                              -resizeGL()
                              -paintGL()
                              -mousePressEvent()
                              -mouseMoveEvent()
                              -mouseReleaseEvent()
                              slots
                              -iconFinished()
                              -replyError()




    User Interface
Code Reuse



• WebKit
• MVC Framework
Code Reuse


• WebKit
 • Scaled Image Display
 • Automatic progress bar handling
• MVC Framework
Code Reuse
• WebKit
• MVC Framework
 • QTreeView (the view)
 • QStandardItem (the model)
   • Inherits QAbstractItemModel
   • data provided by Flickr API
Code Reuse



• WebKit
• MVC Framework
flickr.Collection        1
                                                                                +title: String
                                                flickr.User                      +description: String
         flickr.Flickr                                                           +iconSmall: String
signals                        +id: String
                               +name: String                                    +sets: List<Photoset>
+userFound(User)                                                                +collections: List<Collection>
+Flickr()                      +collections: List<Collection>
                               +publicPhotos: Hashtable<String, Photo>      *   ~Collection()                    *
+findUserBy(value)                                                                                1
+findUserById(userId)           +collectedPhotosets: List<Photoset>
                               +photosets: List<Photoset>              1                       *
+findUserByEmail(email)                                                                  flickr.Photoset
+findUserByUsername(username)   signals
                                                                                    +id
slots                          +getInfoFinished()
                                                                                    +primary
-replyError(code)              +getPublicPhotosFinished()
                                                                                    +secret
-findUserFinished()             +getCollectionsFinished()
                                                                                    +server
                               +getPhotosetsFinished()
                                                                        1           +farm
                               ~User()
                                                                                *   +title
                               +getInfo()
                                                                                    +description
                               +getPublicPhotos()
                                                                                    +photos
                               +getCollections()
                                                                                    slots
                               +getPhotosets()
                                                                                    +getPhotosFinished
                               slots
                                                                                    ~Photoset()
                               -getInfoFinished()
                                                                                    +getPhotos()
                               -getPublicPhotosFinished()
                                                                                    slots
                               -getCollectionsFinished()
                                                                                    -getPhotosFinished()
                               -getPhotosetsFinished()                                           1
                                                                                                *
                                                                                          flickr.Photo
                                                                                       +id
                                                                                       +secret
                                                                                       +server
                                                                                       +farm
                                                                                       +title
                                                                                       +originalSecret
                                                                                       +originalFormat
                                                                                       ~Photo()
                                                                                       +url(Size): QUrl




          Flickr Package
MainWindow                       flickr.User             QNetwork




               getPublicPhotos

                                                    get



                                                finished


         getPublicPhotosFinished




Asynchronous Comm
Caching



• Network Disk Cache
• Image Cache
Caching


• Network Disk Cache
 • XML responses
 • Downloaded images and icons
• Image Cache
Caching

• Network Disk Cache
• Image Cache
 • QPixmapCache
 • In memory caching of icons and
   images
Challenges


• Platform specific libraries
  • (Especially JOGL)
• Complicates delivery
Delivery

• Java Web Start
 • Qt Jambi libraries
 • JOGL libraries
• http://mentaldistortion.com/app/
  gazr/gazr.jnlp
Demo



• The second video contains a
  demonstration.
Thank You

More Related Content

What's hot

State of GeoTools 2012
State of GeoTools 2012State of GeoTools 2012
State of GeoTools 2012Jody Garnett
 
C++ classes tutorials
C++ classes tutorialsC++ classes tutorials
C++ classes tutorialskksupaul
 
CG OpenGL Shadows + Light + Texture -course 10
CG OpenGL Shadows + Light + Texture -course 10CG OpenGL Shadows + Light + Texture -course 10
CG OpenGL Shadows + Light + Texture -course 10fungfung Chen
 
The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212Mahmoud Samir Fayed
 
รายงานคอม
รายงานคอมรายงานคอม
รายงานคอมAreeya Onnom
 
รายงานคอม
รายงานคอมรายงานคอม
รายงานคอมAreeya Onnom
 
The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181Mahmoud Samir Fayed
 
Programação assíncrona utilizando Coroutines
Programação assíncrona utilizando CoroutinesProgramação assíncrona utilizando Coroutines
Programação assíncrona utilizando CoroutinesDiego Gonçalves Santos
 
07 2
07 207 2
07 2a_b_g
 
Zend Framework 1 + Doctrine 2
Zend Framework 1 + Doctrine 2Zend Framework 1 + Doctrine 2
Zend Framework 1 + Doctrine 2Ralph Schindler
 
Creating Custom Charts With Ruby Vector Graphics
Creating Custom Charts With Ruby Vector GraphicsCreating Custom Charts With Ruby Vector Graphics
Creating Custom Charts With Ruby Vector GraphicsDavid Keener
 
The Ring programming language version 1.5.1 book - Part 44 of 180
The Ring programming language version 1.5.1 book - Part 44 of 180The Ring programming language version 1.5.1 book - Part 44 of 180
The Ring programming language version 1.5.1 book - Part 44 of 180Mahmoud Samir Fayed
 
X2 T06 01 Discs & Washers
X2 T06 01 Discs & WashersX2 T06 01 Discs & Washers
X2 T06 01 Discs & WashersNigel Simmons
 
Particle Filter Tracking in Python
Particle Filter Tracking in PythonParticle Filter Tracking in Python
Particle Filter Tracking in PythonKohta Ishikawa
 

What's hot (20)

State of GeoTools 2012
State of GeoTools 2012State of GeoTools 2012
State of GeoTools 2012
 
C++ classes tutorials
C++ classes tutorialsC++ classes tutorials
C++ classes tutorials
 
CG OpenGL Shadows + Light + Texture -course 10
CG OpenGL Shadows + Light + Texture -course 10CG OpenGL Shadows + Light + Texture -course 10
CG OpenGL Shadows + Light + Texture -course 10
 
The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212
 
รายงานคอม
รายงานคอมรายงานคอม
รายงานคอม
 
Coding for
Coding for Coding for
Coding for
 
รายงานคอม
รายงานคอมรายงานคอม
รายงานคอม
 
mobl
moblmobl
mobl
 
DDS-20m
DDS-20mDDS-20m
DDS-20m
 
The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181
 
Programação assíncrona utilizando Coroutines
Programação assíncrona utilizando CoroutinesProgramação assíncrona utilizando Coroutines
Programação assíncrona utilizando Coroutines
 
07 2
07 207 2
07 2
 
Prototype UI Intro
Prototype UI IntroPrototype UI Intro
Prototype UI Intro
 
Zend Framework 1 + Doctrine 2
Zend Framework 1 + Doctrine 2Zend Framework 1 + Doctrine 2
Zend Framework 1 + Doctrine 2
 
Creating Custom Charts With Ruby Vector Graphics
Creating Custom Charts With Ruby Vector GraphicsCreating Custom Charts With Ruby Vector Graphics
Creating Custom Charts With Ruby Vector Graphics
 
Clojure Deep Dive
Clojure Deep DiveClojure Deep Dive
Clojure Deep Dive
 
The Ring programming language version 1.5.1 book - Part 44 of 180
The Ring programming language version 1.5.1 book - Part 44 of 180The Ring programming language version 1.5.1 book - Part 44 of 180
The Ring programming language version 1.5.1 book - Part 44 of 180
 
X2 T06 01 Discs & Washers
X2 T06 01 Discs & WashersX2 T06 01 Discs & Washers
X2 T06 01 Discs & Washers
 
Particle Filter Tracking in Python
Particle Filter Tracking in PythonParticle Filter Tracking in Python
Particle Filter Tracking in Python
 
Oo ps
Oo psOo ps
Oo ps
 

Viewers also liked (9)

Conte sant jordi definitiu
Conte sant jordi definitiuConte sant jordi definitiu
Conte sant jordi definitiu
 
Conte sant jordi
Conte sant jordiConte sant jordi
Conte sant jordi
 
It bi retail
It bi retailIt bi retail
It bi retail
 
As pp
As ppAs pp
As pp
 
Intelligence
IntelligenceIntelligence
Intelligence
 
Healthy
Healthy Healthy
Healthy
 
Orientee(2)
Orientee(2)Orientee(2)
Orientee(2)
 
Le temps passe
Le temps passeLe temps passe
Le temps passe
 
José miguel escobar
José miguel escobarJosé miguel escobar
José miguel escobar
 

Similar to Gazr

A Layered Architecture for the Model-driven Development of Distributed Simula...
A Layered Architecture for the Model-driven Development of Distributed Simula...A Layered Architecture for the Model-driven Development of Distributed Simula...
A Layered Architecture for the Model-driven Development of Distributed Simula...Daniele Gianni
 
Swift for tensorflow
Swift for tensorflowSwift for tensorflow
Swift for tensorflow규영 허
 
Cocos2dを使ったゲーム作成の事例
Cocos2dを使ったゲーム作成の事例Cocos2dを使ったゲーム作成の事例
Cocos2dを使ったゲーム作成の事例Yuichi Higuchi
 
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたスマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたTaro Matsuzawa
 
Intro to Game Programming
Intro to Game ProgrammingIntro to Game Programming
Intro to Game ProgrammingRichard Jones
 
Orchid Programming
Orchid ProgrammingOrchid Programming
Orchid Programmingrayhsu
 
The Ring programming language version 1.10 book - Part 39 of 212
The Ring programming language version 1.10 book - Part 39 of 212The Ring programming language version 1.10 book - Part 39 of 212
The Ring programming language version 1.10 book - Part 39 of 212Mahmoud Samir Fayed
 
Cyber-Physical Cloud Computing
Cyber-Physical Cloud ComputingCyber-Physical Cloud Computing
Cyber-Physical Cloud ComputingKyoung-Sook Kim
 
Introduction to Digital Image Processing
Introduction to Digital Image ProcessingIntroduction to Digital Image Processing
Introduction to Digital Image ProcessingJulio Seaman
 
Use C++ to Manipulate mozSettings in Gecko
Use C++ to Manipulate mozSettings in GeckoUse C++ to Manipulate mozSettings in Gecko
Use C++ to Manipulate mozSettings in GeckoChih-Hsuan Kuo
 
Adventures In Data Compilation
Adventures In Data CompilationAdventures In Data Compilation
Adventures In Data CompilationNaughty Dog
 
Mary Had a Little λ (QCon)
Mary Had a Little λ (QCon)Mary Had a Little λ (QCon)
Mary Had a Little λ (QCon)Stephen Chin
 
Open Computer Vision Based Image Processing
Open Computer Vision Based Image ProcessingOpen Computer Vision Based Image Processing
Open Computer Vision Based Image ProcessingNEEVEE Technologies
 
Cross platform Mobile development on Titanium
Cross platform Mobile development on TitaniumCross platform Mobile development on Titanium
Cross platform Mobile development on TitaniumYiguang Hu
 
Game development with Cocos2d
Game development with Cocos2dGame development with Cocos2d
Game development with Cocos2dVinsol
 
Appengine Java Night #2b
Appengine Java Night #2bAppengine Java Night #2b
Appengine Java Night #2bShinichi Ogawa
 
A Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsA Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsMichael Pirnat
 

Similar to Gazr (20)

A Layered Architecture for the Model-driven Development of Distributed Simula...
A Layered Architecture for the Model-driven Development of Distributed Simula...A Layered Architecture for the Model-driven Development of Distributed Simula...
A Layered Architecture for the Model-driven Development of Distributed Simula...
 
Real life XNA
Real life XNAReal life XNA
Real life XNA
 
Swift for tensorflow
Swift for tensorflowSwift for tensorflow
Swift for tensorflow
 
Cocos2dを使ったゲーム作成の事例
Cocos2dを使ったゲーム作成の事例Cocos2dを使ったゲーム作成の事例
Cocos2dを使ったゲーム作成の事例
 
My favorite slides
My favorite slidesMy favorite slides
My favorite slides
 
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたスマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
 
Intro to Game Programming
Intro to Game ProgrammingIntro to Game Programming
Intro to Game Programming
 
Orchid Programming
Orchid ProgrammingOrchid Programming
Orchid Programming
 
The Ring programming language version 1.10 book - Part 39 of 212
The Ring programming language version 1.10 book - Part 39 of 212The Ring programming language version 1.10 book - Part 39 of 212
The Ring programming language version 1.10 book - Part 39 of 212
 
Cyber-Physical Cloud Computing
Cyber-Physical Cloud ComputingCyber-Physical Cloud Computing
Cyber-Physical Cloud Computing
 
Introduction to Digital Image Processing
Introduction to Digital Image ProcessingIntroduction to Digital Image Processing
Introduction to Digital Image Processing
 
Use C++ to Manipulate mozSettings in Gecko
Use C++ to Manipulate mozSettings in GeckoUse C++ to Manipulate mozSettings in Gecko
Use C++ to Manipulate mozSettings in Gecko
 
Adventures In Data Compilation
Adventures In Data CompilationAdventures In Data Compilation
Adventures In Data Compilation
 
Core animation
Core animationCore animation
Core animation
 
Mary Had a Little λ (QCon)
Mary Had a Little λ (QCon)Mary Had a Little λ (QCon)
Mary Had a Little λ (QCon)
 
Open Computer Vision Based Image Processing
Open Computer Vision Based Image ProcessingOpen Computer Vision Based Image Processing
Open Computer Vision Based Image Processing
 
Cross platform Mobile development on Titanium
Cross platform Mobile development on TitaniumCross platform Mobile development on Titanium
Cross platform Mobile development on Titanium
 
Game development with Cocos2d
Game development with Cocos2dGame development with Cocos2d
Game development with Cocos2d
 
Appengine Java Night #2b
Appengine Java Night #2bAppengine Java Night #2b
Appengine Java Night #2b
 
A Few of My Favorite (Python) Things
A Few of My Favorite (Python) ThingsA Few of My Favorite (Python) Things
A Few of My Favorite (Python) Things
 

Gazr

  • 1. Flickr Browser - Gazr Blanton Black
  • 3. Motivation • Visual Experience • Like Cover Flow • Fluid animation of large photosets • Speed
  • 4. Motivation • Visual Experience • Speed • Fast browsing (view more at once) • Heavy caching • Standalone Application
  • 5. Platform • Java • Qt Jambi • Asynchronous APIs • OpenGL • 3D animation
  • 6. Photo Organization • User • Collections (Nested) • Sets • Photos
  • 8. Kinetic Scrolling • Bézier curve • Velocity control • Movement triggers sound effect
  • 9. Kinetic Scrolling • Bézier curve • Smoothly interpolated from 0 to 1 • 3-dimensional cooridinates • Velocity control • Movement triggers sound effect
  • 10. Kinetic Scrolling • Bézier curve • Smoothly interpolated from 0 to 1 • 3-dimensional cooridinates • Velocity control • Movement triggers sound effect
  • 11. Kinetic Scrolling • Bézier curve • Velocity control • Drag to accelerate • Click and hold to brake • Movement triggers sound effect
  • 12. Kinetic Scrolling • Bézier curve • Velocity control • Movement triggers sound effect • Custom made
  • 13. Kinetic Scrolling • Bézier curve • Velocity control • Movement triggers sound effect • Custom made
  • 15. QObject QWidget QMainWindow QGLWidget Vector3 +x Gazr Flowr +y Attribute -gl: GL +z Attribute -glu: GLU +plus(v: Vector3): Vector3 slots -ctrlPoints: List<Vector3> +times(v: double): Vector3 on_flowr_photoClicked(photo) -velocity: double lerp(a: Vector3, b: Vector3): Vector3 * -sound: MediaObject signals +photoClicked<Photo> 1 +Flowr() +setPhotos() -preDraw() -drawCurve() -drawImages() events -timerEvent() -initializeGL() -resizeGL() -paintGL() -mousePressEvent() -mouseMoveEvent() -mouseReleaseEvent() slots -iconFinished() -replyError() User Interface
  • 16. Code Reuse • WebKit • MVC Framework
  • 17. Code Reuse • WebKit • Scaled Image Display • Automatic progress bar handling • MVC Framework
  • 18. Code Reuse • WebKit • MVC Framework • QTreeView (the view) • QStandardItem (the model) • Inherits QAbstractItemModel • data provided by Flickr API
  • 19. Code Reuse • WebKit • MVC Framework
  • 20. flickr.Collection 1 +title: String flickr.User +description: String flickr.Flickr +iconSmall: String signals +id: String +name: String +sets: List<Photoset> +userFound(User) +collections: List<Collection> +Flickr() +collections: List<Collection> +publicPhotos: Hashtable<String, Photo> * ~Collection() * +findUserBy(value) 1 +findUserById(userId) +collectedPhotosets: List<Photoset> +photosets: List<Photoset> 1 * +findUserByEmail(email) flickr.Photoset +findUserByUsername(username) signals +id slots +getInfoFinished() +primary -replyError(code) +getPublicPhotosFinished() +secret -findUserFinished() +getCollectionsFinished() +server +getPhotosetsFinished() 1 +farm ~User() * +title +getInfo() +description +getPublicPhotos() +photos +getCollections() slots +getPhotosets() +getPhotosFinished slots ~Photoset() -getInfoFinished() +getPhotos() -getPublicPhotosFinished() slots -getCollectionsFinished() -getPhotosFinished() -getPhotosetsFinished() 1 * flickr.Photo +id +secret +server +farm +title +originalSecret +originalFormat ~Photo() +url(Size): QUrl Flickr Package
  • 21. MainWindow flickr.User QNetwork getPublicPhotos get finished getPublicPhotosFinished Asynchronous Comm
  • 22. Caching • Network Disk Cache • Image Cache
  • 23. Caching • Network Disk Cache • XML responses • Downloaded images and icons • Image Cache
  • 24. Caching • Network Disk Cache • Image Cache • QPixmapCache • In memory caching of icons and images
  • 25. Challenges • Platform specific libraries • (Especially JOGL) • Complicates delivery
  • 26. Delivery • Java Web Start • Qt Jambi libraries • JOGL libraries • http://mentaldistortion.com/app/ gazr/gazr.jnlp
  • 27. Demo • The second video contains a demonstration.
  • 28.

Editor's Notes

  1. Hello, my name is Blanton Black, and I wrote an application called Gazr, which is an alternative browser for the Flickr photo sharing site.
  2. In short, my goal for this project was to create a flowing visual experience.
  3. In order to provide a fluid view of photos, I implemented my own widget. Similar in concept to Apple&amp;#x2019;s Cover Flow, my OpenGL based animation presents a continuous stream of photos. This allows a user to visually scan a potentially large photoset.
  4. In terms of speed, it is not difficult to improve upon a browser based paged interface. Clicking through page after page of photos is time consuming. Gazr&amp;#x2019;s approaches is to download and cache thumbnails in the background, presenting them in a continuous animated interface. No more click and wait.
  5. In terms of platform, the flickr browser is written in Java. However, the user interface is not based on Swing. Instead, Gazr uses bindings for the cross platform Qt application framework. In addition, 3D animation is provided by OpenGL. Both of these libraries sit on top of platform specific dynamic libraries. On the positive side, this gives the application a performance boost by providing hardware graphics acceleration. Unfortunately, this requires the distribution of platform specific libraries, but I will revisit this topic later.
  6. Flickr provides various ways of browsing, ranging from searches, to groups, to tags. Nevertheless, this prototype focuses on Flickr users. The application starts by fetching a given user&amp;#x2019;s information. Then, Gazr will fetch the collection hierarchy, and display the information in a tree widget for browsing. It looks something like this.
  7. And here is the interface. Collections and sets are on the upper left. Meanwhile, the view on the lower left provides the flowing animation of an individual photoset. Finally, clicking on a photo within the animation will load a larger version of the image on the right.
  8. The scrolling animation uses a few tricks.
  9. First there is the curve. The curve maps a scalar from 0 to 1 to a point in 3-dimensional space.
  10. In this way, rendering a photo in 3D space is as simple as determining its position from 0 to 1, mapping it along the curve, and drawing it at its 3-dimensional position.
  11. The animation&amp;#x2019;s velocity is controlled by the mouse. For example, you can click, drag, and release, to start the scrolling animation. This allows for a rapid or slow paced view of each photo. In addition, the user can slow down the process by clicking and holding, which decreases the velocity.
  12. Yet another feature is the sound effect when the image is first dragged, which sounds like....
  13. Next, I will cover some design details.
  14. Here, we have the widget design. The user interface was developed with 2 major classes, plus one helper Vector class. That is slightly misleading, because the application framework is based on a MVC framework, plus a significant amount of code reuse.
  15. Although I did not extend any of my own classes, there is a heavy amount of code reuse inherent in the Qt application framework.
  16. For example, I could have written my own image display widget to provide scaling. However, the WebKit module already does this for me. Consequently, the large image display is really nothing more than a webkit browser window, with a black background, that is instructed to load images from the web.
  17. Another example of the code reuse involves the MVC framework. For example, the main window renders collections and sets with a QTreeView. I considered creating my own model based upon the abstract interface, but soon discovered that this does not translate well to Java, due to its lack of pointers. So, instead of subclassing the abstract model, i created an instance of QStandardItemModel, which already implements the abstract class. Then, I use data from the flickr api to populate this model with titles, descriptions, and icons.
  18. Using Qt&amp;#x2019;s reusable components significantly cuts back on the overall application complexity, allowing me to focus on data logic, which is contained within the flickr package.
  19. Most of the application&amp;#x2019;s processing is contained here. Basically, the flickr package is a wrapper around xml services provided by flickr. It is not a 1 to 1 mapping with the Flickr REST API. Nevertheless, I would like to highlight the signals and slots pattern. For example, once the Flickr class resolves a user, the user class then provides a number of methods that will go out to the network. For each network operation, the user has a corresponding slot to received feedback from the network operations. The user object also has signals of its own, so that it may emit responses back to the above application.
  20. One of the key requirements for a fluid experience is having an interface that never blocks. The Qt framework accomplishes this by providing an asynchronous networking library. In the sequence diagram above, notice that all of the messages are asynchronous. Nothing blocks. For example, when the application wants to show a photoset, it will call getPublicPhotos. The User object, in turn, asks the QNetwork library to fetch the data for a given url. Some time in the future, the network response replies with either an error or finished signal. In the case of a finished signal, the User will catch this in a signal slot, parse the xml data, and then emit its own signal to the main window, informing it that the photoset data is ready. At this point, the MainWindow can update the widgets with the pre-processed data. The entire application uses these non-blocking techniques.
  21. Performance was a major design consideration. In order to keep the experience as fast as possible, Gazr uses two levels of caching.
  22. First, the network system has a dedicated caching mechanism. By default, all network requests are fetched and stored to disk. For instance, downloading a full image can take several seconds. However, if the image is brought up again, the network subsystem can automatically load the image from disk.
  23. Compared to a network request, loading an image from the disk is fast. However, loading from memory is even faster. Once again, Qt has a class specifically for this purpose. The pixmap cache stores a limited amount of data, such that going back and forth between two recent images is virtually instantaneous.
  24. Both Jambi and the java opengl bindings consist of non-Java platform specific code. This complicates distribution by requiring the addition of platform specific jar files. For Jambi, this was straightforward. However, finding the right bindings for the opengl bindings proved difficult. In short, their website is a mess, such that finding the right pre-compiled libraries involved copious amounts of trial and error.
  25. To get around this problem, I explored Java Web Start. In fact, you can try Gazr by navigating to the above URL. The provided XML file contains the necessary data to bootstrap the program over the web, without taking the time to perform an actual install. Most importantly, however, Web Start will download the appropriate support libraries for the specific system on which the program will run. In theory, as long as Java and Web Start are installed, Gazr should just work on most systems.
  26. Finally, I have prepared a video demonstration. I would like to point out, however, that the screen capture program used a rather low frame rate. The actual program&amp;#x2019;s animation is significantly smoother.