MoinMoin Gource Video
This page describes the process used to make a visualisation of activity in the MoinMoin 2.0-dev repository, and the video produced.
What is Gource?
From their website:
Gource is a software version control visualization tool. Software projects are displayed by Gource as an animated tree with the root directory of the project at its centre. Directories appear as branches with files as leaves. Developers can be seen working on the tree at the times they contributed to the project.
A Gource video can be used both as a tool to analyse development of a project over time and as impressive eye candy.
Process used to create the video
Note: This requires FFmpeg and Gource (tested with version 0.28) to be installed on your system.
The steps involved in creating the video are:
- Gource reads the Mercurial logs and outputs it's rendering to the screen and to stdout in the form of a PPM stream.
- The PPM stream is piped to FFmpeg, which turns the stream into a high quality video.
- The high quality video of Gource's output can be converted to lower quality formats for sharing or uploaded to a video sharing website in it's high definitino form.
The following command achieves steps one and two, with step three left as an exercise for the reader if it is required:
cd /path/to/moin/repo/ gource --multi-sampling -1024x768 --output-ppm-stream - --disable-progress --hide mouse -a 0.015 --camera-mode overview --logo MoinMoin/static/common/moinmoin_alpha.png --max-file-lag=0.01 --max-user-speed 2000 -s 0.15 --stop-at-end --title "MoinMoin 2.0-dev Repository - Activity Visualisation" --user-friction 0.1 --background-colour 000000 --start-position 0.35782339652293488 | ffmpeg -y -b 3000k -r 60 -f image2pipe -vcodec ppm -i - -vcodec libvpx -b 3000K -r 25 gourcevis.mkv
This will create a video named "gourcevis.mkv" in the current directory. The arguments passed to Gource tell it to:
- Enable multi-samping (increasing video quality)
- Have a resolution of 1024x768
- Output a PPM stream to stdout
- Disable the progress indicator
- Prevent the mouse from being displayed
- Skip to rendering the next commit if Gource is idle for more than one second
- Make the camera give an overview of the project (rather than tracking areas of high activity)
- Place a logo watermark in the lower right hand corner
- Allow a maximum of 0.01 seconds between a commit and when the file appears on screen
- Make the maximum user avatar speed 2000 units/second
- Have each day account for 0.15 seconds
- Stop at the end of the log
- Set the title of the output
- Make user avatars take a maximum of 0.1 seconds to come to a complete halt
- Set the background colour to #000000
- Start at the first Summer of Code 2008 commit (the value 0.35782339652293488 will decrease with every commit)
After this a "title" image and "credits" image were made with GIMP and placed at the beginning and end of the video using Kdenlive.