Writing multimedia applications with Grilo
Upcoming SlideShare
Loading in...5
×
 

Writing multimedia applications with Grilo

on

  • 606 views

Talk about how Totem and GNOME Music use Grilo to get access to multimedia content.

Talk about how Totem and GNOME Music use Grilo to get access to multimedia content.

Talk from GUADEC 2013.

Statistics

Views

Total Views
606
Views on SlideShare
540
Embed Views
66

Actions

Likes
0
Downloads
5
Comments
0

2 Embeds 66

https://twitter.com 48
http://presentz.org 18

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

CC Attribution-ShareAlike LicenseCC Attribution-ShareAlike License

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Writing multimedia applications with Grilo Writing multimedia applications with Grilo Presentation Transcript

  • static void _g_digicam_manager_class_init (GDigicamManagerClass *klass) { GObjectClass *object_class = (GObjectClass*) klass; g_assert (G_DIGICAM_IS_MANAGER_CLASS (klass)); parent_class = g_type_class_peek_parent (klass); g_type_class_add_private (klass, sizeof (GDigicamManagerPrivate)); /* Override virtual functions */ object_class->finalize = _g_digicam_manager_finalize; /** * GDigicamManager::focus-done: * @manager: the gdigicam manager Juan A. Suárez Romero jasuarez@igalia.com Writing multimedia applications with Grilo
  • Opening
  • Sources
  • Sources
  • Grilo ● Framework focused on making discovery and browsing easy for application developers ● A single, high-level API for all the sources ● Plugins ● Provides access to multimedia content ● Extendable
  • Grilo SOURCESOURCESOURCE SOURCESOURCEMEDIA SOURCESOURCE METADATA KEYS creates contains provides Youtube Jamendo Flickr IMDB ... Audio Video Image ... Title Artist Album ...
  • Totem
  • Totem
  • Requirements ● Define what we need ● Type of content – Any kind? – Only video? Music? ● Metadata keys – URL – Title – Thumbnail – ... 55 metadata keys
  • Content to show ● Ignore any source that does not provide Videos ● In “browse” view, ignore any source that does not support browsing ● In “search” view, ignore any source that does not support searching
  • Information to show - Title - Author - Duration - Thumbnail - URL - Title - Author - Duration - Thumbnail - URL Browse Search
  • Invoke Grilo - Title - Author - Duration - Thumbnail - URL - Title - Author - Duration - Thumbnail - URL Browse Search
  • Problems ● Two problems to solve ● Source not handling some keys ● Too much expensive to retrieve some keys
  • Totem ● Flags to control content retrieval ● Normal: provides the known requested content – GRL_RESOLVE_NORMAL ● Fast only: provides the known requested content that does not penalize the operation in terms of performance – GRL_RESOLVE_FAST_ONLY ● Full: provides the known requested content using all the available sources – GRL_RESOLVE_FULL
  • Reduce the problems ● Request content in chunks ● Request fast only in first iteration ● While current chunk is visible ● Ask for each visible media element the discarded keys (using full flag) ● URL key case: slow key and not shown in the UI ● Request it when user wants to play
  • GNOME Music
  • GNOME Music Cover Art
  • GNOME Music ● Music defines its own structure ● Grilo's one is different ● Does not have concept of “Artist” or “Album” ● They are “boxes” ● Needs to sort the results
  • GNOME Music
  • Approaches ● Request content from Tracker directly ● Create Grilo Media elements to add missing information (Cover Art) ● Instruct Grilo's Tracker plugin how to construct the medias ● Use query() function ● Very specific to the plugin ● In case of Tracker plugin, use SPARQL to make the query – First column is the media to build – Use alias to map each SPARQL column to specific metadata keys
  • Closing
  • Other use-cases ● Application to upload audio/video content to web services ● store() function ● Mediaplayer with auto-resume ● “playback-interrupted-time” key ● store_metadata() function – Metadata Store source handles it
  • Show me a code
  • Resources ● Wiki ● http://live.gnome.org/Grilo ● Source code ● git://git.gnome.org/grilo ● git://git.gnome.org/grilo-plugins ● IRC ● #grilo at irc.gnome.org ● Mailing list ● http://mail.gnome.org/mailman/listinfo/grilo-list