diff -r 000000000000 -r 06009f72d657 branches/gmyth-0.1b/src/gmyth_recorder.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/branches/gmyth-0.1b/src/gmyth_recorder.h Tue Feb 13 23:17:35 2007 +0000
@@ -0,0 +1,122 @@
+/**
+ * GMyth Library
+ *
+ * @file gmyth/gmyth_recorder.h
+ *
+ * @brief
GMythRecorder class defines functions for playing live tv.
+ *
+ * Copyright (C) 2006 INdT - Instituto Nokia de Tecnologia.
+ * @author Hallyson Luiz de Morais Melo
+ *
+ *//*
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program 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 Lesser General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef __GMYTH_RECORDER_H__
+#define __GMYTH_RECORDER_H__
+
+#include
+
+#include "gmyth_socket.h"
+#include "gmyth_programinfo.h"
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+G_BEGIN_DECLS
+
+#define GMYTH_RECORDER_TYPE (gmyth_recorder_get_type ())
+#define GMYTH_RECORDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GMYTH_RECORDER_TYPE, GMythRecorder))
+#define GMYTH_RECORDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GMYTH_RECORDER_TYPE, GMythRecorderClass))
+#define IS_GMYTH_RECORDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GMYTH_RECORDER_TYPE))
+#define IS_GMYTH_RECORDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GMYTH_RECORDER_TYPE))
+#define GMYTH_RECORDER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GMYTH_RECORDER_TYPE, GMythRecorderClass))
+
+
+typedef struct _GMythRecorder GMythRecorder;
+typedef struct _GMythRecorderClass GMythRecorderClass;
+
+struct _GMythRecorderClass
+{
+ GObjectClass parent_class;
+
+ /* callbacks */
+ /* no one for now */
+};
+
+struct _GMythRecorder
+{
+ GObject parent;
+
+ /* socket descriptor */
+ GMythSocket *myth_socket;
+
+ gint recorder_num;
+ GString *hostname;
+ gint port;
+};
+
+typedef enum _GMythRecorderChannelChangeDirection {
+ CHANNEL_DIRECTION_UP = 0,
+ CHANNEL_DIRECTION_DOWN,
+ CHANNEL_DIRECTION_FAVORITE,
+ CHANNEL_DIRECTION_SAME
+} GMythRecorderChannelChangeDirection;
+
+GType gmyth_recorder_get_type (void);
+
+GMythRecorder* gmyth_recorder_new (int num,
+ GString *hostname,
+ gshort port);
+
+gboolean gmyth_recorder_setup (GMythRecorder *recorder);
+gboolean gmyth_recorder_spawntv (GMythRecorder *recorder,
+ GString *tvchain_id);
+
+gboolean gmyth_recorder_spawntv_no_tvchain (GMythRecorder *recorder);
+
+gboolean gmyth_recorder_stop_livetv (GMythRecorder *recorder);
+
+gboolean gmyth_recorder_send_frontend_ready_command (GMythRecorder *recorder);
+
+gboolean gmyth_recorder_check_channel (GMythRecorder *recorder, gint channel);
+
+gboolean gmyth_recorder_check_channel_name (GMythRecorder *recorder, gchar* channel);
+
+gboolean gmyth_recorder_set_channel (GMythRecorder *recorder,
+ gint channel);
+
+gboolean gmyth_recorder_set_channel_name (GMythRecorder *recorder,
+ const gchar* channel);
+
+gboolean gmyth_recorder_change_channel (GMythRecorder *recorder,
+ const GMythRecorderChannelChangeDirection direction);
+
+gboolean gmyth_recorder_pause_recording ( GMythRecorder *recorder );
+
+GMythProgramInfo *gmyth_recorder_get_current_program_info ( GMythRecorder *recorder );
+
+gint64 gmyth_recorder_get_file_position ( GMythRecorder *recorder );
+
+gboolean gmyth_recorder_is_recording ( GMythRecorder *recorder );
+
+G_END_DECLS
+
+#endif /* __GMYTH_REMOTE_ENCODER_H__ */