summaryrefslogtreecommitdiff
path: root/src/libspudec/spu_decoder_api.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/libspudec/spu_decoder_api.h')
-rw-r--r--src/libspudec/spu_decoder_api.h69
1 files changed, 69 insertions, 0 deletions
diff --git a/src/libspudec/spu_decoder_api.h b/src/libspudec/spu_decoder_api.h
new file mode 100644
index 000000000..4dfd2739a
--- /dev/null
+++ b/src/libspudec/spu_decoder_api.h
@@ -0,0 +1,69 @@
+/*
+ * spu_decoder_api.h
+ *
+ * Copyright (C) James Courtier-Dutton James@superbug.demon.co.uk - July 2001
+ *
+ * This file is part of xine, a unix video player.
+ *
+ * xine is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * xine is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GNU Make; see the file COPYING. If not, write to
+ * the Free Software Foundation,
+ *
+ */
+
+#ifndef HAVE_SPU_API_H
+#define HAVE_SPU_API_H
+
+ /*
+ * generic xine spu decoder plugin interface
+ *
+ * for a dynamic plugin make sure you provide this function call:
+ * spu_decoder_t *init_spu_decoder_plugin (int iface_version,
+ * config_values_t *cfg);
+ */
+
+typedef struct spu_decoder_s spu_decoder_t;
+
+struct spu_decoder_s {
+
+ int interface_version;
+
+ int (*can_handle) (spu_decoder_t *this, int buf_type);
+
+ void (*init) (spu_decoder_t *this, vo_instance_t *video_out);
+
+ void (*decode_data) (spu_decoder_t *this, buf_element_t *buf);
+
+ void (*close) (spu_decoder_t *this);
+
+ char* (*get_identifier) (void);
+
+};
+
+
+
+typedef struct spudec_s spudec_t;
+
+struct spudec_s {
+
+ /*
+ * reset spudec for a new stream
+ *
+ * clut : pointer to array of 16 cluts for palette info
+ */
+
+ void (*spudec_start) (spudec_t *this, clut_t *clut);
+
+};
+
+#endif /* HAVE_SPUDEC_H */