Mercurial > mplayer.hg
annotate stream/pvr.h @ 36802:621b61818a0f
configure: add -Zhigh-mem linker flag for OS/2
x264 encoder crashes due to memory allocation failure. This fixes the problem.
author | komh |
---|---|
date | Thu, 20 Feb 2014 13:59:34 +0000 |
parents | 8abdc84493f3 |
children |
rev | line source |
---|---|
23246 | 1 /* |
26737
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
2 * stream layer for hardware MPEG 1/2/4 encoders a.k.a PVR |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
3 * (such as WinTV PVR-150/250/350/500 (a.k.a IVTV), pvrusb2 and cx88) |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
4 * See http://ivtvdriver.org/index.php/Main_Page for more details on the |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
5 * cards supported by the ivtv driver. |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
6 * |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
7 * Copyright (C) 2006 Benjamin Zores |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
8 * Copyright (C) 2007 Sven Gothel (Channel Navigation) |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
9 * |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
10 * This file is part of MPlayer. |
23246 | 11 * |
26737
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
12 * MPlayer is free software; you can redistribute it and/or modify |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
13 * it under the terms of the GNU General Public License as published by |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
14 * the Free Software Foundation; either version 2 of the License, or |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
15 * (at your option) any later version. |
23246 | 16 * |
26737
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
17 * MPlayer is distributed in the hope that it will be useful, |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
20 * GNU General Public License for more details. |
23246 | 21 * |
26737
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
22 * You should have received a copy of the GNU General Public License along |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
23 * with MPlayer; if not, write to the Free Software Foundation, Inc., |
a26e50cae389
Use standard license headers with standard formatting.
diego
parents:
26184
diff
changeset
|
24 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
23246 | 25 */ |
26 | |
26029 | 27 #ifndef MPLAYER_PVR_H |
28 #define MPLAYER_PVR_H | |
23244
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
29 |
26184
7ee4ae1648e6
Add missing header #includes to fix 'make checkheaders'.
diego
parents:
26029
diff
changeset
|
30 #include "stream.h" |
23244
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
31 #include "tv.h" |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
32 |
31419
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
33 extern char *pvr_param_audio_mode; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
34 extern char *pvr_param_bitrate_mode; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
35 extern char *pvr_param_stream_type; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
36 |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
37 extern int pvr_param_aspect_ratio; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
38 extern int pvr_param_audio_bitrate; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
39 extern int pvr_param_audio_layer; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
40 extern int pvr_param_bitrate; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
41 extern int pvr_param_bitrate_peak; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
42 extern int pvr_param_sample_rate; |
8abdc84493f3
Move pvr_ extern variable declarations to stream/pvr.h.
diego
parents:
29263
diff
changeset
|
43 |
23244
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
44 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
45 * @brief Get the current station name. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
46 * The pointer is valid, till the stream is closed. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
47 * @return The stream's station name |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
48 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
49 const char *pvr_get_current_stationname (stream_t *stream); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
50 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
51 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
52 * @brief Get the current channel name. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
53 * The pointer is valid, till the stream is closed. |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
26737
diff
changeset
|
54 * @return The stream's channel name |
23244
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
55 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
56 const char *pvr_get_current_channelname (stream_t *stream); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
57 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
58 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
59 * @brief Get the current frequency. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
60 * @return frequency |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
61 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
62 int pvr_get_current_frequency (stream_t *stream); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
63 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
64 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
65 * @brief Set the current station using the channel name. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
66 * This function will fail, |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
67 * if the channel does not exist, or the station is not enabled |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
68 * @return 0 if the station is available, otherwise -1 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
69 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
70 int pvr_set_channel (stream_t *stream, const char *channel); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
71 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
72 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
73 * @brief Set the current station using to the last set channel |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
74 * @return 0 if the station is available, otherwise -1 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
75 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
76 int pvr_set_lastchannel (stream_t *stream); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
77 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
78 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
79 * @brief Set the current channel using the frequency. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
80 * This function will fail, |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
81 * if the frequency does not exist, or the station is not enabled |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
82 * @return 0 if the station is available, otherwise -1 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
83 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
84 int pvr_set_freq (stream_t *stream, int freq); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
85 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
86 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
87 * @brief Set the current station while stepping. |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
88 * This function will fail, |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
89 * if the station does not exist, or the station is not enabled |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
90 * @return 0 if the station is available, otherwise -1 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
91 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
92 int pvr_set_channel_step (stream_t *stream, int step); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
93 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
94 /** |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
95 * @brief Set the current frequency while stepping |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
96 * This function will fail, |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
97 * if the frequency is invalid, i.e. <0 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
98 * @return 0 if success, otherwise -1 |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
99 */ |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
100 int pvr_force_freq_step (stream_t *stream, int step); |
e5e8ac0bd7fc
support for PVR channel navigation (patch by Sven Gothel <sgothel at jausoft dot com>)
ben
parents:
diff
changeset
|
101 |
26029 | 102 #endif /* MPLAYER_PVR_H */ |