# include "config.h"
#endif
-#include <vlc/vlc.h>
+#include <vlc_common.h>
+#include <vlc_plugin.h>
#include <vlc_demux.h>
#include "vlc_codec.h"
#include "vlc_meta.h"
#include "vlc_input.h"
#include "../codec/cc.h"
+#include <assert.h>
+
/*****************************************************************************
* Module descriptor
*****************************************************************************/
static void Close( vlc_object_t * );
vlc_module_begin();
- set_shortname( _("TY") );
- set_description(_("TY Stream audio/video demux"));
+ set_shortname( N_("TY") );
+ set_description(N_("TY Stream audio/video demux"));
set_category( CAT_INPUT );
set_subcategory( SUBCAT_INPUT_DEMUX );
- set_capability("demux2", 6);
+ set_capability("demux", 6);
/* FIXME: there seems to be a segfault when using PVR access
* and TY demux has a bigger priority than PS
* Something must be wrong.
U32_AT(&p_peek[8]) != CHUNK_SIZE )
{
if( !p_demux->b_force &&
- !demux2_IsPathExtension( p_demux, ".ty" ) &&
- !demux2_IsPathExtension( p_demux, ".ty+" ) )
+ !demux_IsPathExtension( p_demux, ".ty" ) &&
+ !demux_IsPathExtension( p_demux, ".ty+" ) )
return VLC_EGENERIC;
msg_Warn( p_demux, "this does not look like a TY file, "
"continuing anyway..." );
//subrec_type, esOffset1);
p_sys->lastVideoPTS = get_pts(
&p_block_in->p_buffer[ esOffset1 + VIDEO_PTS_OFFSET ] );
- /*msg_Dbg(p_demux, "Video rec %d PTS "I64Fd, p_sys->i_cur_rec,
+ /*msg_Dbg(p_demux, "Video rec %d PTS %"PRId64, p_sys->i_cur_rec,
p_sys->lastVideoPTS );*/
if (subrec_type != 0x06) {
/* if we found a PES, and it's not type 6, then we're S2 */
/* seek within the chunk to get roughly to where we want */
p_sys->i_cur_rec = (int)
((double) ((seek_pos % CHUNK_SIZE) / (double) (CHUNK_SIZE)) * p_sys->i_num_recs);
- msg_Dbg(p_demux, "Seeked to file pos " I64Fd, seek_pos);
+ msg_Dbg(p_demux, "Seeked to file pos %"PRId64, seek_pos);
msg_Dbg(p_demux, " (chunk %d, record %d)",
p_sys->i_cur_chunk - 1, p_sys->i_cur_rec);