/*****************************************************************************
- * vlc_stream.h
+ * vlc_stream.h: Stream (between access and demux) descriptor and methods
*****************************************************************************
- * Copyright (C) 1999-2004 VideoLAN
+ * Copyright (C) 1999-2004 the VideoLAN team
* $Id$
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#ifndef _VLC_STREAM_H
#define _VLC_STREAM_H 1
+# ifdef __cplusplus
+extern "C" {
+# endif
+
/**
* \defgroup stream Stream
*
/* Special for direct access control from demuxer.
* XXX: avoid using it by all means */
- STREAM_CONTROL_ACCESS, /* arg1= int i_access_query, args res: can fail
- if access unreachable or access control answer */
+ STREAM_CONTROL_ACCESS /* arg1= int i_access_query, args res: can fail
+ if access unreachable or access control answer */
};
/**
void (*pf_destroy)( stream_t *);
stream_sys_t *p_sys;
+
+ /* UTF-16 and UTF-32 file reading */
+ vlc_iconv_t conv;
+ int i_char_width;
+ vlc_bool_t b_little_endian;
};
/**
va_list args;
int i_result;
+ if ( s == NULL )
+ return VLC_EGENERIC;
+
va_start( args, i_query );
i_result = s->pf_control( s, i_query, args );
va_end( args );
#define stream_MemoryNew( a, b, c, d ) __stream_MemoryNew( VLC_OBJECT(a), b, c, d )
VLC_EXPORT( stream_t *,__stream_MemoryNew, (vlc_object_t *p_obj, uint8_t *p_buffer, int64_t i_size, vlc_bool_t i_preserve_memory ) );
#define stream_UrlNew( a, b ) __stream_UrlNew( VLC_OBJECT(a), b )
-VLC_EXPORT( stream_t *,__stream_UrlNew, (vlc_object_t *p_this, char *psz_url ) );
+VLC_EXPORT( stream_t *,__stream_UrlNew, (vlc_object_t *p_this, const char *psz_url ) );
/**
* @}
*/
+# ifdef __cplusplus
+}
+# endif
+
#endif