Older blog entries for ensonic (starting at number 108)

tracking down udev hangs

I still face some problems on my new computer system. One of them iswas that udev was hanging in 8/10 cases at bootup. Thanks to great support from the udev folks I learned how to track it down. I previously tried to add options to /etc/udev/udev.conf (e.g. to raise the log level), but one can actually just add them to the kernel options. This has the great advantage that they don't persist. Things you want to add to debug are:

udev.log-priority=info udev.children-max=1 udev.exec-delay=1

This logs a lot of things (the boot can go from 30 second to minutes, so be patient). The option children-max is turning parallel event execution off and exec-delay is delaying run actions. With those I saw that the system hangs when loading the cdrom.ko kernel module. As I had some problems with the drive as well I swapped it and now bootup is fine.

working on multimedia for MeeGo at Nokia

If you like to work on free software and like snow - we're having a few open positions:

Ping me on irc (ensonic @ freenode/gimpnet) if you have questions.
buzztard

After some more work bt-dec starts to works better. I can now play buzztard songs in totem, banshee and co. I still see some issues with seeking though.

I have be going through my pending gtk bugs and patches. I can see a lot of activity in gtk+ these days. People have been helpful reviewing and commenting the changes. I could close two of my bugs with patches to code and docs committed. At the same time I also understand a few things better and reworked the focus handling on the tabs. Instead of listening to focus notifies and then grabbing the primary widget on the page, I am now overriding the focus vmethod and grab there. The disadvantage of the previous method was that the widget has to be realized and mapped, but when you receive the notify for the tab switch, it is not necessarily the case yet.

There were some changes on the logging in gstreamer. I had to adjust some parts of my tests that where intercepting log messages.

I've started to migrate all modules to use G_DEFINE_TYPE, G_DEFINE_INTERFACE and GST_BOILERPLATE macros to shorten the code. I hope I can finish it next month. At the same time I have cleaned-up my gobject use:

  • remove dummy vmethod implementations (empty property setters/getter)
  • no need to check for dispose/finalize in parent class (just chain up, they always exist)

I improved the error handling in the commandline client and also in the ui (when rendering to disk). It catches and handles missing element messages now. Before the processing could hang if that happened :/

While doing more work on the changelog I noticed that I could also use that to show last save date when warning about unsaved changes. The change log uses UTC timestamps, so I had to convert them. I haven't found any nice API for this (like give a date and tell what tz it is and ask to convert to local or any other tz). The startup check for old change logs does now some auto cleanup and sanity checks. Next I'll add some ui for picking one for recovery.

I recently upgraded on machine to suse 11.3. After that all machine icons where in the wrong size. After some digging I noticed that the gnome/index.theme misses all the 'scalable' entries and that seems to break my svg icons. I have added a workaround, but with that I get 48x48 png scaled up. Readding the missing entries works. I filed a bug, but nobody feels responsible so far :/

Bored from all the refactoring and bug fixing I hacked a bit on the spectrum analyser. Its now using cairo (no more gdk_draw_*) and thus is ready for gtk3 and looks much nicer. In addition is can do log plots and one can increase the resolution.

While playing with orc for gstreamer and googling for simd information, I can across some info about the gcc autovectorizer. One can ask for quite verbose reports of gcc attempting to use simd for loops. I could improve the performance in a few place based on the reports. Unfortunately the only places where the vectorization finally succeeded where those where I just should have used memset() :/

78 files changed, 4300 insertions(+), 1832 deletions(-)

Lintian complained about missing man-pages for buzztard binaries. I also had a pending bug for gtk-doc to clarify how one can do man-pages. Last month I wrong some docs about how to document binaries in docbook as well, so that the information is in the api-docs, but one can also generate man pages from the same source. The new guides are not yet on library.gnome.org, but it can be found in git.

I continued with more undo/redo hacking. I have again more tests that all pass and working undo/redo in pattern editor for trivial operations. Need to do edit-groups next and work more on the journal replay part. The testing work resulted in some local check improvements - the BT_CHECKS env-var supports globbing to select tests. Also patched that for gstreamers GST_CHECKS env-var.

While showing buzztard to a colleague I noticed that the audio settings where not used for the sample players. Fixed in svn.

In the early days I made some mistakes in the xml design of the song format. Some tags had different attributes depending on their parent. This makes it impossible to do xsd schema validation. I have changed the song xml slightly (with backwards compatibility of old songs) and now xsd validation works.

Finally I have started buzztard-bin. This is supposed to be a gstreamer plugin that plugs a whole buzztard song, so that one can play that in e.g. totem. The basics are there, should be working quite soon.

83 files changed, 2452 insertions(+), 624 deletions(-)

buzztard

The packaging continued - I found a Gentoo overlay that has buzztard packages, as well as packages for Arch Linux. The later brought up some issues as arch Linux uses --as-needed when linking. An article in the Gentoo documentation suggests that its not a good idea to use this by default. To cut the long story short - normally (without that option) the order of libraries in the linker invocation did not really matter. When using --as-needed only libraries that are actually used are linked in. To make that work one has to put needed libraries behind libraries that need them. If you want to try this on your own software: LDFLAGS="-Wl,--as-needed" ./autoregen.sh

The Debian packages that have been made recently are nice too. All packages undergo various checks, among a spell-checker of strings in binaries.

As planned I worked a bit more on undo/redo. I have it now implemented and in use for some case in the pattern editor. I also added unit tests to verify the stack logic.

I also managed to finished some work I had started at the Linux Audio Conference - copy and paste of machine parameters between patterns and the machine property window.

54 files changed, 2174 insertions(+), 699 deletions(-)

buzztard

It is nice to see that more and more distros have buzztard packages. Many thanks to Sebastian Dröge for submitting packages to Debian and Ubuntu.

Latest GStreamer releases (gst-plugins-base-0.10.28) have my adder fixes. With those trick playback in buzztard works much better. Scrubbing is not locking up any more and we can play the score forward and backward at different speeds. There seems to be still an issue in more complex songs though. Every time the playback accelerates, the sink is waiting for something and thus there is a pause.

One major feature I'd like to have for 0.6 is undo/redo and journaling. The latter is important to minimize the loss of data in case the application or the system crashes. I have been thinking for quite a while how to implement it and came to the conclusion that it can be made so that journaling means having a serializable redo stack. I have now started to write the code for it. Hopefully more news on how it went soon.

48 files changed, 2240 insertions(+), 351 deletions(-)

buzztard

I will give a talk about "Writing audio applications using gstreamer" at the Linux Audio Conference 2010. Naturally quite some time went for writing the article. Now that it has been accepted, I need to start working on the slides and demos.

In buzztard I've tried to make the life of people that use jack or pulse a bit easier. The problem here is that the player is only visible in jack/pulse when it is actually playing. I have now some code that keeps the sink alive (in GST_STATE_READY). This allows e.g. changing the volume in pulse or routing the output in QJackCtrl even if the app is not playing. Unfortunately it only works after the sink was in playing once. I need to confirm my theory of what wrong still.

I recently brought a netbook (MSI L1300) and thus wanted to try buzztard on this machine. I have installed moblin 2.1 on it to play with moblin. As usual, installing own software on a new linux distro/machine always brings up something. After a few rounds of configure maintenance and dependency trimming I am set and having it running. Performance seems to be okay even for complex songs. Yay!

Besides that, I fixed a few more bugs and wrote more tests.

gtk-doc, xslt and profiling

As part of the endless journey of getting gtk-doc to spit out the docs faster I managed to get xsltproc from libxslt to output full callgraphs. The output is compatibe with oprofile and thus the same tools to rendering can be used (e.g. gprof2dot). Bit sadly me profiles hit a python assertion in the above code which I have to disable to run it, buug filed but dormant since 1 month. Same for the xsltproc patch, the patch and an example image is here but no reviews so far.

Now the way to make gtk-doc faster would be to make the xslt faster and as I can see from the profile, this could be done, by preprocessing the xsl with some variables set. Right now I have not too high hopes on this as libxslt seems quite dormant and this is not so straight forward :/

buzztard

As if February isn't short enough already, a nasty stomach infection send me to the couch (and bathroom) for a couple of days.

Still managed to do a couple of things. Some refactoring in the editor allowed me to harmonize context menus, e.g. one can open machine windows also from pattern and sequence view.

GStreamer has support for accelerated and decelerated playback, forward and backward. I started to overhaul the seek handling a bit and added UI for fast- forward and fast-backward. Fast-forward is working with some limitations, but reverse playback needs some fixes in plugins still. As a side effect one can now scrub with the mouse over the timeline.

I also wrote a standalone test app for my level meter. I was still not convinced that is was always drawing correctly. Indeed there was a bug in the resize behaviour, that now is fixed too.

As gtk+3 comes closer I did several rounds of adapting the the new style to use accessor functions everywhere.

44 files changed, 1087 insertions(+), 317 deletions(-)

buzztard

I couldn't really concentrate one a single task this months. Thus I ended up with lots of small changes here and there. First obvious change is that buzztard got an over-engineered tip-of-the-day dialog. I takes extra care to present tips in random order, without repeating tips before you have seen them all. I also played a bit with parasite - the cool gtk ui introspector and noticed that my dialogs are inconsistently layouted. Well, fixed now.

Besides I did lots of small cleanups and refactorings. GStreamer pipelines load faster as I now link pads directly (not elements). This also gives me better diagnostics if it goes wrong. I could get rid of some dead code, removed a lot of double checking and generally lowered the amount of gobject runtime type checks. I also turned some more objects into proper gobject singletons. This way I don't need to pass them around anymore.

Finally I wrote some test code in preparation of adding device selection to the audio settings (like selecting the alsa device). Need to make a plan of how to store the selection for multiple sinks.

173 files changed, 6014 insertions(+), 5939 deletions(-)

gtk-doc

I worked most of the December time on gtk-doc. After more that a year I released 1.12 and 1.13 on the same day:). Most notable features are probably that now one can have syntax highlighted and xreffed examples and the generated indexes have a prefix detection. That means the index has proper a,b,c sections and not everything under 'g' for for gnome libraries. The best thing - you don't need to do anything, just update your gtk-doc version. Now I hope that someone kindly installs 'highlight' (or 'gnu-highlight') on the server that runs library.gnome.org (or do we need them on build.gnome.org?) so that we get the highlighted docs there too.

Now if you want to do something, have a look at these two commits and do the same in your package. It helps maintenance and it builds faster. If you want even more speedups go for gtk-doc from git head. I managed to tweak the xslt to save a third of build time. I mostly replaced some templates to avoid i18n which the api-docs don't use anyway, but also cached some nodesets.

buzztard

On buzztard I also spent a little time, improving the docs and pushing the test coverage further. I will attack the bullets on the 0.6 roadmap next. Happy new year and stay tuned.

99 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!