Search:  
Gentoo Wiki

HOWTO_Setup_MythTV_in_Framebuffer

This article is part of the HOWTO series.
Installation Kernel & Hardware Networks Portage Software System X Server Gaming Non-x86 Emulators Misc

MythTV Series

MythTV

Installation

Tips/Tweaking

Usage

edit

Contents

Introduction

This HOWTO describes how to setup MythTV on a framebuffer device using DirectFB and QT Embedded.

Why would you want to install MythTV on a framebuffer ?

Before you start, check that your videocard is properly supported by DirectFB.

Sidenote : my adventures with DirectFB and MythTV
Several years ago, I bought an LCD projector in order to realize my dream : build my own home theatre. The system should have a nice user interface that enables you to watch videos, tv, dvd and pictures. After careful investigation I bought a Panasonic PT-AE300. Since I already had a Matrox G450 graphics card, I started looking for the best possible drivers for my card under Linux. After a long time looking at X drivers, special mplayer drivers I finally ended up at DirectFB : they developed a thin graphics layer on top of the framebuffer device that gives access to all possible hardware features of this card. I attended a presentation of the lead developer, Denis Oliver Kropp at the Open Source Fosdem Conference in Brussels, Belgium. Immediately I was impressed by the possibilities and smoothness that DirectFB presented compared to a slow X window giant. Would it not be great if MythTV would display its video using DirectFB ? The giant could turn into a sleek elf. In december 2004 my dream came true : someone posted on the MythTV development mailing list that he succeeded in running MythTV on the framebuffer.


Architecture

DirectFB is used for displaying MythTV video-output in the framebuffer. To display other video formats, df_xine can be used. This is a xine frontend for DirectFB. It is part of the dev-libs/DirectFB-extra ebuild.

QT-embedded displays the MythTV UI in the framebuffer.

Prerequisites

You have a framebuffer device setup for your videocard.

DirectFB installation

VIDEO_CARDS=<your video card> emerge dev-libs/DirectFB

Possible video cards are :

ati128 cle266 cyber5k i810 mach64 matrox neomagic 
nsc nvidia radeon savage sis315 tdfx unichrome

Before starting, make sure that DirectFB is configured correctly. For extra options, you can always look at man directfbrc.

File: /etc/directfbrc
fbdev=/dev/fb<your fb device>

Optional : test DirectFB installation

Now for the fun part : let's see what DirectFB does :-)

NOTE: the DirectFB-extra package was split. You now need DirectFB-examples to get these examples. There is no ebuild in portage, but its easy enough to copy the one for DirectFB-extra and make it work:

# mkdir /usr/local/portage/dev-libs/DirectFB-examples
# cp -R /usr/portage/dev-libs/DirectFB-extra /usr/local/portage/dev-libs/DirectFB-examples
-- Go in the new directory and rename everything from "extra" to "examples" --
-- Edit the ebuild for DirectFB-examples and change the source URI to ... downloads/DirectFB-extra/${P}.tar.gz --
# ebuild /usr/local/portage/dev-libs/DirectFB-examples-??? digest
emerge dev-libs/DirectFB-extra dev-libs/DirectFB-examples

This package contains several DirectFB examples.

Go ahead and run some tests :

df_dok      - the DirectFB benchmark application, runs some tests and 
              displays benchmark results afterwards

If you cannot get enough, get the penguins jumping :

df_andi     - penguin demo, press space to form convergence logo, 
              s/d to spawn/destroy a penguin, r to revive penguin
              after space was pressed, c tests clipping

Other examples (nice to have good README files !)

df_databuffer - a simple test application for data buffers
df_fire     - the famous fire effect ported to DirectFB (16 bpp only)
df_fonts    - takes a list of font files and shows character tables
df_input    - a test application for input devices
df_joystick - colored version of df_particle, fointain can be moved with 
              joystick, particles of different colors can be spawned
              with different joystick  buttons (1-4)
df_knuckles - a 3D skull drawn using triangles that can be rotated using
              the mouse. Space switches to wireframe, b toggles backface
              culling
       
df_neo      - port from a gdk-pixbuf demo to DirectFB, uses scaling,
              alpha blending and color modulation; use cursor keys and
              space to change parameters
df_particle - a moving fountain consisting of alphablended rectangles,
              nice and fast if hardware accelerated
df_porter   - shows porter/duff blending rules
df_stress   - stress tests surface manager, for debugging purposes only
df_window   - simple demonstration of the DirectFB window stack, follow
              the instructions in the upper left corner. Pass a video
              device file or a movie file on the command-line to enable
              video playback in one of the windows.
df_video    - shows window stack with alpha blending and video playback
              in a moving window
df_video_particle - same as df_particle, but the rectangles have been
              replaced by a video (via video4linux). Nice color effects.
pss         - some funky screen animations
spacedream  - an interactive starfield simulation using color modulation
              use mouse to change viewpoint, cursor keys to move

QT/Embedded installation

# echo "x11-libs/qt-embedded -cups" >> /etc/portage/package.use
# emerge x11-libs/qt-embedded

Once installed, lets test!

MythTV installation

We now have a working framebuffer with DirectFB and QT-embedded running on it.

20 Feb 2007: In the current 0.20 version of MythTV that's available in Portage, this implementation seems to be broken. See the thread on the Gentoo forums: http://forums.gentoo.org/viewtopic-p-3919197.html#3919197 The only other reference I have been able to find that indicates these steps are incomplete is here: http://www.mythtv.org/wiki/index.php/MythTV_in_Framebuffer [Bob May]

Retrieved from "http://www.gentoo-wiki.info/HOWTO_Setup_MythTV_in_Framebuffer"

Last modified: Mon, 25 Aug 2008 03:26:00 +0000 Hits: 22,172