libavg Features

High-Level Overview

  • Hardware-accelerated display mixer and screen layout engine.
  • High-performance video playback.
  • Text layout.
  • Sophisticated camera support.
  • Python scripting.
  • Skinnable widget library.
  • Input from mouse, keyboard, touch, computer vision.
  • Built-in animation support.
  • Offscreen rendering and compositing.
  • GPU-based shader effects.
  • Plugins written in C++ for maximum performance.

Screen Layout Engine

The screen layout engine is at the heart of avg. It is responsible for dealing with graphical elements (images, videos, text, camera output) in a generic way and can deal with thousands of objects. Among others, it supports:

  • Hierarchial layouts
  • Cropping
  • Scaling
  • Rotation
  • Element-level transparency
  • Image alpha channels
  • Separate mask bitmaps
  • Various blend modes
  • Subpixel precision for smooth animations
  • Hardware-accelerated OpenGL rendering
  • Warping and mirroring of elements

Video

  • Playback pause and restart, playback at user-determined framerates
  • Complete display engine integration, including cropping, scaling, rotation and transparency.
  • Videos with an alpha channel are supported.
  • Very high performance. Video decoding is accelerated using shaders if available or sse2 assembly if not. Can display several full HD or hundreds of very small videos without frame losses.
  • Seeks at interactive rates: Essentially, libavg allows random access to the frames of full HD videos without delays using mjpg files.

Text

  • Paragraph-level layout using html < div >-like syntax
  • Bold/italic etc.
  • Colored text
  • Left-/Right-justified as well as centered paragraphs
  • Kerning and antialiasing
  • Full internationalization using utf8: Arabic, Chinese and Hebrew are all rendered correctly and can be mixed. Right-to-left text is supported.
  • Custom letter and line spacing
  • Layout - including font face and size - changes in mid-paragraph

Vector Graphics

libavg supports vector nodes rendered on the GPU. Available vector node types are Line, PolyLine, Curve, Circle, Polygon and Rectangle. Vector nodes can be textured, with the closed vectors taking two textures: one for the outline, one for the fill.

GPU Effects

GPU Effects can be used to manipulate what is being displayed. Effects available are:

  • Blur
  • ChromaKey
  • Hue/Saturation manipulation
  • Color Inversion
  • Shadows

In addition, it's easy to build new effects as plugins.

Multitouch

  • Support for all common multitouch driver models:
    • Linux XInput 2.1
    • Linux libmtdev
    • TUIO
    • Win 7 Touch
  • Built-in FTIR and DI tracking.
  • Powerful event handling for multitouch events.
  • Direct manipulation support.

Sound

libavg supports mixing of an unlimited amount of stereo sounds with a high-quality limiter to avoid artifacts on volume spikes. It supports alsa on linux and core audio on Mac OS X for low-latency sound output.

Camera Support

libavg supports a wide variety of firewire and USB cameras. Setting camera parameters such as brightness, exposure, saturation and gamma is also possible.

Animation

libavg has built-in support for smooth time-based animations. Any numeric attribute of a node - x, y, angle, etc. - can be animated with a single line of code to create linear and spline-based movements.

Tracking

libavg supports camera tracking and multitouch surfaces (FTIR and DI) using all supported cameras.

Authoring

All of python is available for scripting. libavg directly provides:

  • Properties of display elements as python variables
  • Full-featured event handling system
  • Timers (setTimeout, setInterval)
  • Support for logging
  • High-level profiling to find performance bottlenecks
  • High-precision frame timing and synchronization to vertical blanking for smooth animations

Plugin Support

Plugins written in C++ have access to all libavg internals and can define complete new node types, including xml and python interface.