Track listings with foobar2000

From BakaBT Wiki
Jump to navigation Jump to search

Uploaders of soundtracks and OSTs will quickly find generating tracklists to be a pain. The task is repetitive and highly tedious—exactly the sort of thing best done by software tools. Foobar2000 is one such tool that can do this, among many other things.

What you need

  1. foobar2000
  2. Text Tools plugin for foobar2000
  3. Audio tracks from which to generate a filelist, properly tagged with track number, track title, and any other required info.

Procedure

  • Install foobar2000.
  • Install the Text Tools plugin using the Components menu in Preferences.

Figure 1: foobar2000 Components.

  • Add tracks to foobar2000 by click-dragging them into the foobar2000 window.
  • Select all the tracks to generate the tracklist from, ensuring they are in desired order.
  • Right-click on the selected tracks → Utilities → Text Tools. You will see a few pre-configured options. You can use these, but we can do one step better and add own own custom patterns to make things even easier. These can be added or edited through the Customize option in Text Tools menu.

Figure 2: foobar2000 Text Tools copying patterns.

Notice that there are tags within those patterns, such as %track%, %title%, and so on. These tags are replaced with track info when you generate the tracklist with Text Tools. A full list of tags can be found on Hydrogenaudio wiki. Some of the commonly used tags are listed below.

  • %album artist%
  • %album%
  • %artist%
  • %title%
  • %tracknumber%

Give your new copying pattern an easily identifiable name. Now you should see the new pattern in the Utilities → Text Tools context menu.

Examples

HTML <ol> lists

If you are using HTML ordered lists to display your tracklist, the HTML code will look something like:

[...]
<ol>
<li>Track 1</li>
<li>Track 2</li>
<li>Track 3</li>
</ol>
[...]

foobar2000 can add the <> tags for you with Text Tools. From the Text Tools list, click Customize. You should now see a list of preconfigured copying patterns. For a simple <ol>...</ol> list of track titles, we can use the following pattern:

<li>%title%</li>

This will copy the track titles of all selected tracks and encase them within <li> tags. Since it’s an ordered list, track numbers are automatically be added (if your list is in the correct order).

HTML <select> lists

The code for <select> lists looks like:

[...]
<select>
<option>3 tracks
<option>01 - Track 1
<option>02 - Track 2
<option>03 - Track 3
</select>
[...]

We can use the following pattern to generate this:

<option>%tracknumber% - %title%

This will copy the track numbers and titles (hyphen-separated) of all selected tracks, and prepend the <option> tag.