 +#include "libswscale/swscale.h"
 +
 +#ifdef HAVE_OGGKATE
++
 +#include <kate/kate.h>
-+#endif
-+
-+#ifdef HAVE_OGGKATE
 +
 +/* if no canvas size if specified, default to DVD size, that's a good guess */
 +#define DEFAULT_CANVAS_WIDTH 720

   {
diff -ruN -x 'config.*' -x configure.log -x '*.o' -x allformats.c -x vidix -x codecs.conf.h -x version.h -x help_mp.h mplayer-svn/subreader.c mplayer-svn-with-kate/subreader.c
--- mplayer-svn/subreader.c	2008-03-14 13:27:01.000000000 +0000
+++ mplayer-svn-with-kate/subreader.c	2008-10-09 08:49:31.000000000 +0100
@@ -24,6 +24,12 @@
 #include <enca.h>
 #endif

+  (*draw_alpha_ptr)(x0,y0,w,h,tda_y,tda_a,stride);
+}
+
+void katedec_draw(unsigned int dxs, unsigned int dys, void (*draw_alpha)(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride))
+{
+  if (katedec_has_kin) {
+    int xpos = katedec_kin.has.region ? (int)(katedec_kin.region_x+0.5f) : 0;
+    int ypos = katedec_kin.has.region ? (int)(katedec_kin.region_y+0.5f) : 0;
