]> git.sesse.net Git - vlc/blobdiff - src/input/input_internal.h
- Added support for embeded cover. Demuxer just need to fill psz_arturl meta
[vlc] / src / input / input_internal.h
index 1ef106c18d5ea5e94a299d45f78e601006839504..d84ffce325e4fc22398af33840d8f2330a05a8aa 100644 (file)
@@ -69,7 +69,6 @@ typedef struct
 struct input_thread_private_t
 {
     /* Global properties */
-    vlc_bool_t  b_can_pace_control;
     vlc_bool_t  b_can_pause;
 
     int         i_rate;
@@ -88,12 +87,14 @@ struct input_thread_private_t
     int         i_bookmark;
     seekpoint_t **bookmark;
 
-    /* Global meta datas FIXME move to input_item_t ? */
-    vlc_meta_t  *p_meta;
+    /* Input attachment */
+    int i_attachment;
+    input_attachment_t **attachment;
 
     /* Output */
     es_out_t    *p_es_out;
     sout_instance_t *p_sout;            /* XXX Move it to es_out ? */
+    vlc_bool_t      b_sout_keep;
     vlc_bool_t      b_out_pace_control; /*     idem ? */
 
     /* Main input properties */
@@ -127,7 +128,8 @@ struct input_thread_private_t
     int i_control;
     struct
     {
-        /* XXX: val isn't duplicated so it won't works with string */
+        /* XXX for string value you have to allocate it before calling
+         * input_ControlPush */
         int         i_type;
         vlc_value_t val;
     } control[INPUT_CONTROL_FIFO_SIZE];
@@ -221,10 +223,22 @@ vlc_bool_t  input_MetaSatisfied ( playlist_t*, input_item_t*,
                                   uint32_t*, uint32_t* );
 int         input_DownloadAndCacheArt ( playlist_t *, input_item_t * );
 
+/* Becarefull; p_item lock HAS to be taken */
+void input_ExtractAttachmentAndCacheArt( input_thread_t *p_input );
+
 /***************************************************************************
  * Internal prototypes
  ***************************************************************************/
 
+/* misc/stats.c */
+input_stats_t *stats_NewInputStats( input_thread_t *p_input );
+
+/* input.c */
+#define input_CreateThreadExtended(a,b,c,d) __input_CreateThreadExtended(VLC_OBJECT(a),b,c,d)
+input_thread_t *__input_CreateThreadExtended ( vlc_object_t *, input_item_t *, const char *, sout_instance_t * );
+
+void input_DestroyThreadExtended( input_thread_t *p_input, sout_instance_t ** );
+
 /* var.c */
 void input_ControlVarInit ( input_thread_t * );
 void input_ControlVarClean( input_thread_t * );
@@ -239,16 +253,15 @@ void stream_AccessDelete( stream_t *s );
 void stream_AccessReset( stream_t *s );
 void stream_AccessUpdate( stream_t *s );
 
-/* decoder.c FIXME make it public ?*/
-void       input_DecoderDiscontinuity( decoder_t * p_dec );
+/* decoder.c */
+void       input_DecoderDiscontinuity( decoder_t * p_dec, vlc_bool_t b_flush );
 vlc_bool_t input_DecoderEmpty( decoder_t * p_dec );
-void       input_DecoderPreroll( decoder_t *p_dec, int64_t i_preroll_end );
 
 /* es_out.c */
 es_out_t  *input_EsOutNew( input_thread_t * );
 void       input_EsOutDelete( es_out_t * );
 es_out_id_t *input_EsOutGetFromID( es_out_t *, int i_id );
-void       input_EsOutDiscontinuity( es_out_t *, vlc_bool_t b_audio );
+void       input_EsOutDiscontinuity( es_out_t *, vlc_bool_t b_flush, vlc_bool_t b_audio );
 void       input_EsOutSetDelay( es_out_t *, int i_cat, int64_t );
 vlc_bool_t input_EsOutDecodersEmpty( es_out_t * );
 
@@ -333,4 +346,38 @@ static inline int demux2_Control( demux_t *p_demux, int i_query, ... )
     return i_result;
 }
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__)
+# warning CAN'T YOU SEE THIS IS AN INTERNAL HEADER?! '
+#else
+/* Stream */
+/**
+ * stream_t definition
+ */
+struct stream_t
+{
+    VLC_COMMON_MEMBERS
+
+    block_t *(*pf_block)  ( stream_t *, int i_size );
+    int      (*pf_read)   ( stream_t *, void *p_read, int i_read );
+    int      (*pf_peek)   ( stream_t *, uint8_t **pp_peek, int i_peek );
+    int      (*pf_control)( stream_t *, int i_query, va_list );
+    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;
+};
+
+#include <libvlc.h>
+
+static inline stream_t *vlc_stream_create( vlc_object_t *obj )
+{
+    return (stream_t *)vlc_custom_create( obj, sizeof(stream_t),
+                                          VLC_OBJECT_STREAM, "stream" );
+}
+#endif
+
 #endif