Cheese TNG: less libcheese, more D-Bus

25
GUADEC The Conference History Future Summary Cheese TNG: less libcheese, more D-Bus David King <[email protected]> 2014-07-29 / GUADEC

Transcript of Cheese TNG: less libcheese, more D-Bus

Page 1: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Cheese TNG: less libcheese, more D-Bus

David King <[email protected]>

2014-07-29 / GUADEC

Page 2: Cheese TNG: less libcheese, more D-Bus

Shouldn’t that be "amigodave"?

Page 3: Cheese TNG: less libcheese, more D-Bus

Keeping the Amiga alive

Page 4: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

In the beginning

Started as a GSoC 2007 project by Daniel SiegelFirst released as part of GNOME 2.22Initially conceived as a Photobooth clone

Page 5: Cheese TNG: less libcheese, more D-Bus

2.22

Page 6: Cheese TNG: less libcheese, more D-Bus

2.22

Page 7: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Early development

GSoC projects to add better GNOME integration (FelixKaser) and OpenGL effects (Filippo Argiolas)auto-detection of camera devices with HAL, later udevsplit into a library by Bastien Nocera in 2.29UI rewritten in Vala in 2.31

Page 8: Cheese TNG: less libcheese, more D-Bus

2.28

Page 9: Cheese TNG: less libcheese, more D-Bus

Picard does not like Vala

Page 10: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

GNOME 3

split off effects into gnome-video-effectsuse clutter for video widgetlots of GtkApplication and GTK+ 3 porting by PatriciaSantana Cruz as part of Openismus trainee program (andlater OPW)I joined as a maintainer around 3.2.0

Page 11: Cheese TNG: less libcheese, more D-Bus

New Cheese maintainer

Page 12: Cheese TNG: less libcheese, more D-Bus

3.2

Page 13: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Post-GNOME3 development

port to GStreamer 1.0 and camerabin2composite widget templatesheader barsbetter fullscreen handling (implemented by Rashi Aswani)

Page 14: Cheese TNG: less libcheese, more D-Bus

3.12

Page 15: Cheese TNG: less libcheese, more D-Bus

Picard does not like CSD

Page 16: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Planned design overhaul

thanks to Fabiana and Allanhttps://wiki.gnome.org/Design/Apps/Cheesestreamlined interface with on-canvas (OSD) controlsheader bar and fullscreen mode changes mergedlooking for a willing GSoC student!

Page 17: Cheese TNG: less libcheese, more D-Bus

3.16?

Page 18: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Cheese as a sandboxed application

sandboxed applications will not have access to raw devicenodesit will be necessary to request access to hardware devicesaccess to the webcam should be suspended on logout,screen lock and user switching

Page 19: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Application sandboxing (easy bits)

CheeseAvatarChooser is used to take webcam photos anduse them as avatar imagesreplace in-process libcheese API with an out-of-processD-Bus API to show a chooser dialogueD-Bus service handles requests, shows the dialogue andreturns an image to the applicationno direct access to the V4L2 device is needed by theapplicationprototype implementation exists

Page 20: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Difficulties for advanced applications

Applications like Cheese need access to the video stream,to apply effects and do processingChanging properties of the camera (resolution, brightness,autofocus, and so on) needs access to the device nodeNo good way to enforce permissions on the video devicenode in a user session service

Page 21: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

What about another D-Bus service?

a D-Bus service on the system bus, with exclusivepermission to the video device nodesmove most of the camera properties and video processingof libcheese into the serviceprovide a video stream to sandboxed clientslots of overhead going through the D-Bus server

Page 22: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

PulseVideo?

video is like audio, in that low latency and high(er)throughput is requiredtraditional D-Bus is not fast enoughuse kdbus/memfds as a transportnot too difficult for the Cheese use case, but difficult toexpose all properties and be generic

Page 23: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

History Future Summary

Summary

need to figure out the scope of a video device serverwaiting on memfds and kdbus to be merged into the kernelsandboxing itself is not a hard requirement (but a videoserver is required for better application sandboxing)D-Bus avatar chooser service in 3.14 (hopefully!)

Page 24: Cheese TNG: less libcheese, more D-Bus

Picard loves application sandboxing

Page 25: Cheese TNG: less libcheese, more D-Bus

GUADECThe ConferenceTM

Acknowledgements

Bastien Nocera for all his great workHans de Goede for various patchesDaniel Siegel for starting off the project (and the Laphroaig)Luciana Fujii Pontello for maintenance and GStreamer helpStar Trek: TNG