 +        self.next_index=1
 +
 +    def do_create(self, offset, size):
-+        print 'do_create called with offset %d' % offset
++        #print 'do_create called with offset %d' % offset
 +        sub = self.sub.getSubByIndex(self.next_index)
 +        if sub != None:
 +            text = sub.getSubText()
 +            start_time = sub.getSubStartTime()
 +            end_time = sub.getSubEndTime()
-+            print 'Found sub at %d till %d: %s' % (start_time, end_time, text)
++            #print 'Found sub at %d till %d: %s' % (start_time, end_time, text)
 +            self.next_index += 1
 +            self.buffer = gst.Buffer(text)
 +            self.buffer.timestamp = start_time * gst.MSECOND

+
+#==============================================================================
+    def __on_kate_event(self, pad, buffer):
+        pad_name = self.padmap[pad]
+        #print 'Kate event: %s on pad %s' % ( buffer, pad_name)
+        subs = self.subs[pad_name]

+
+#==============================================================================
+    def check_kate_plugin(self, pad_name):
+        """
+            Checks whether the Kate GStreamer plugin is available, and bails
+            out with an error message if not
+        """
+        if not 'kate' in map(lambda p: p.get_name(), gst.registry_get_default().get_plugin_list()):
+            msg = 'The Kate GStreamer plugin was not found\ncannot use Kate stream %s\n'
+            print msg % pad_name
