2 * stream layer for TV Input, based on previous work from Albeu
4 * Copyright (C) 2006 Benjamin Zores
6 * This file is part of MPlayer.
8 * MPlayer is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * MPlayer is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License along
19 * with MPlayer; if not, write to the Free Software Foundation, Inc.,
20 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
29 #include "libmpdemux/demuxer.h"
36 tv_param_t stream_tv_defaults
= {
39 "europe-east", //chanlist
47 0, //input, used in v4l and bttv
80 0, //hidden_video_renderer;
81 0, //hidden_vp_renderer;
83 0 //normalize_audio_chunks;
86 #define ST_OFF(f) M_ST_OFF(tv_param_t,f)
87 static const m_option_t stream_opts_fields
[] = {
88 {"hostname", ST_OFF(channel
), CONF_TYPE_STRING
, 0, 0 ,0, NULL
},
89 {"filename", ST_OFF(input
), CONF_TYPE_INT
, 0, 0 ,0, NULL
},
90 { NULL
, NULL
, 0, 0, 0, 0, NULL
}
93 static const struct m_struct_st stream_opts
= {
101 tv_stream_close (stream_t
*stream
)
104 m_struct_free(&stream_opts
,stream
->priv
);
108 tv_stream_open (stream_t
*stream
, int mode
, void *opts
, int *file_format
)
111 stream
->type
= STREAMTYPE_TV
;
113 stream
->close
=tv_stream_close
;
114 *file_format
= DEMUXER_TYPE_TV
;
119 const stream_info_t stream_info_tv
= {
122 "Benjamin Zores, Albeu",