mythtv_plugin/gstmythtvsrc.h
author leo_sobral
Wed Sep 20 23:59:48 2006 +0100 (2006-09-20)
branchtrunk
changeset 2 bd3829c2e9c9
permissions -rwxr-xr-x
[svn r3] imported to sf repository
leo_sobral@2
     1
/* vim: set sw=2: -*- Mode: C; tab-width: 2; indent-tabs-mode: t; c-basic-offset: 2; c-indent-level: 2 -*- */
leo_sobral@2
     2
/* GStreamer
leo_sobral@2
     3
 * Copyright (C) <2006> Rosfran Borges <rosfran.borges@indt.org.br>
leo_sobral@2
     4
 *
leo_sobral@2
     5
 * This library is free software; you can redistribute it and/or
leo_sobral@2
     6
 * modify it under the terms of the GNU Library General Public
leo_sobral@2
     7
 * License as published by the Free Software Foundation; either
leo_sobral@2
     8
 * version 2 of the License, or (at your option) any later version.
leo_sobral@2
     9
 *
leo_sobral@2
    10
 * This library is distributed in the hope that it will be useful,
leo_sobral@2
    11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
leo_sobral@2
    12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
leo_sobral@2
    13
 * Library General Public License for more 
leo_sobral@2
    14
 */
leo_sobral@2
    15
leo_sobral@2
    16
#ifndef __GST_MYTHTV_SRC_H__
leo_sobral@2
    17
#define __GST_MYTHTV_SRC_H__
leo_sobral@2
    18
leo_sobral@2
    19
#include <gst/gst.h>
leo_sobral@2
    20
#include <gst/base/gstpushsrc.h>
leo_sobral@2
    21
#include <stdio.h>
leo_sobral@2
    22
leo_sobral@2
    23
#include <gmyth/gmyth_socket.h>
leo_sobral@2
    24
#include "myth_file_transfer.h"
leo_sobral@2
    25
#include "myth_livetv.h"
leo_sobral@2
    26
leo_sobral@2
    27
G_BEGIN_DECLS
leo_sobral@2
    28
leo_sobral@2
    29
#define GST_TYPE_MYTHTV_SRC \
leo_sobral@2
    30
  (gst_mythtv_src_get_type())
leo_sobral@2
    31
#define GST_MYTHTV_SRC(obj) \
leo_sobral@2
    32
  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_MYTHTV_SRC,GstMythtvSrc))
leo_sobral@2
    33
#define GST_MYTHTV_SRC_CLASS(klass) \
leo_sobral@2
    34
  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_MYTHTV_SRC,GstMythtvSrcClass))
leo_sobral@2
    35
#define GST_IS_MYTHTV_SRC(obj) \
leo_sobral@2
    36
  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_MYTHTV_SRC))
leo_sobral@2
    37
#define GST_IS_MYTHTV_SRC_CLASS(klass) \
leo_sobral@2
    38
  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MYTHTV_SRC))
leo_sobral@2
    39
leo_sobral@2
    40
typedef struct _GstMythtvSrc GstMythtvSrc;
leo_sobral@2
    41
typedef struct _GstMythtvSrcClass GstMythtvSrcClass;
leo_sobral@2
    42
leo_sobral@2
    43
struct _GstMythtvSrc {
leo_sobral@2
    44
  GstBaseSrc element;
leo_sobral@2
    45
leo_sobral@2
    46
  /* MythFileTransfer */
leo_sobral@2
    47
  MythFileTransfer *file_transfer;
leo_sobral@2
    48
leo_sobral@2
    49
  MythLiveTV *spawn_livetv;
leo_sobral@2
    50
leo_sobral@2
    51
  gchar *uri_name;
leo_sobral@2
    52
  gchar *user_agent;
leo_sobral@2
    53
leo_sobral@2
    54
  gchar *live_chain_id;
leo_sobral@2
    55
  
leo_sobral@2
    56
  gint mythtv_version;
leo_sobral@2
    57
leo_sobral@2
    58
  guint64 content_size;
leo_sobral@2
    59
leo_sobral@2
    60
  guint64 bytes_read;
leo_sobral@2
    61
leo_sobral@2
    62
  guint64 read_offset;
leo_sobral@2
    63
leo_sobral@2
    64
  gboolean eos;
leo_sobral@2
    65
  
leo_sobral@2
    66
  gboolean do_start;
leo_sobral@2
    67
leo_sobral@2
    68
  gboolean unique_setup;
leo_sobral@2
    69
leo_sobral@2
    70
  gboolean live_tv;
leo_sobral@2
    71
leo_sobral@2
    72
  gint live_tv_id;
leo_sobral@2
    73
leo_sobral@2
    74
  /* MythTV capabilities */
leo_sobral@2
    75
  GstCaps *mythtv_caps;
leo_sobral@2
    76
leo_sobral@2
    77
  /* enable Myth TV debug messages */
leo_sobral@2
    78
  gboolean mythtv_msgs_dbg;
leo_sobral@2
    79
};
leo_sobral@2
    80
leo_sobral@2
    81
struct _GstMythtvSrcClass {
leo_sobral@2
    82
  GstBaseSrcClass parent_class;
leo_sobral@2
    83
};
leo_sobral@2
    84
leo_sobral@2
    85
GType gst_mythtv_src_get_type (void);
leo_sobral@2
    86
leo_sobral@2
    87
G_END_DECLS
leo_sobral@2
    88
leo_sobral@2
    89
#endif /* __GST_MYTHTV_SRC_H__ */