Create a video index template for Fast video indexer

Video index pictures

Fast video indexer is the video capture program to use when you want to create video index pictures. Video Index pictures are a great way to get a quick overview of a video file. One of the less known features of Fast video indexer is that you can customize the generated index pictures completely. This is a simple guide for how to customizing the index picture template for use with long video files. This guide is only to get you started, when you know how to customize the templates your imagination is the limit.

Video indes using original template
Index picture generated with the original index template

Generation of index pictures

Templates in Fast video indexer are standard xslt pages. Even if you don't know xslt it is not hard to change the templates to your liking. An index pictures is generated by Fast video indexer after the program has captured video frames from the video. The program then creates a temporary xml page with a lot of information about the video file including paths to the video and the captured pictures. The temporary xml page is feed to the xslt sheet to generate a temporary html page that is then rendered to the index image. To customize the index picture all you need to do is to change the standard xslt page.

Our goal

The default Fast video indexer template include a header at the top with information about the video file. In the middle of the page there are cells with the captured video frames each with a drop shadow. At the bottom you find a copyright note.

This layout takes a bit of space and if you want to create an index for a long video with screens taken close together the index picture will be very large. I will change the template to not include the header and footer. I will also change the layout to always have four pages per row with a static width of 128 pixels regardless of the size of the videos and no drop shadow.

Editing the templates

First we need to locate the templates and backup them in case we want to use them later. Open the folder where you installed fast video indexer, typically "c:\program files\fastvideoindexer\" and in the data sub folder you will find the index_transform.xslt file. index_transform.xslt is the template file for video indexes. Take a backup copy of it before you start to change it. Next open index_transform.xslt in notepad. The file should look something like this:

View original index picture template

First we will remove the top area with information about the video including the name of the video, the size and length of the video. Find the first <table> and simply remove everything up to and including its </table> tag.

Next we will change the template to have four rows. Find the following lines and change the 3 to a 4.

<xsl:template match="entry[(position()-1) mod 3 = 0]" >
<xsl:for-each select="following-sibling::node()[position() &lt; 3]">
Finally we will remove the drop shadow and change the images to always be 128 in width. Find this code and remove the div tag to change them from:
<div class="wrap1">
  <div class="wrap2">
   <div class="wrap3">
    <img width="{/movie/settings/width}" height="{/movie/settings/height}" src="{file}" border="1" ></img>
   </div>
  </div>
</div>
to:
<img width="128" src="{file}" border="1" ></img>
Do this at both the places for the img tag and we are finished with all changes.

Using the templates

Now start Fast video indexer, add a video to index. Make sure the program is set to create a index page. Start the program and you will soon have a index page using the new template. If you made a mistake with the template you might get an error dialog. If you get the dialog you have an error in your xslt template. Verify the template and try to find the error.

Video indes changed template
Index picture generated with the changed index template

Conclusion

With the template system you have a very powerful system. I just went through some very simple changes but there is nothing stopping you there. It is possible and quite easy to customize templates to generate video indexes matching the look and feel of you web page.

Download

Download fast video indexer
Download the finished new template


Video knowledgebase Download FastVideoIndexer Order FastVideoIndexer

©Copyright 2007,2008 - Fredrik Lönn, all rigths reserved