VLC  3.0.21
fetcher.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * playlist_fetcher.h:
3  *****************************************************************************
4  * Copyright (C) 1999-2008 VLC authors and VideoLAN
5  * $Id$
6  *
7  * Authors: Samuel Hocevar <sam@zoy.org>
8  * ClĂ©ment Stenac <zorglub@videolan.org>
9  *
10  * This program is free software; you can redistribute it and/or modify it
11  * under the terms of the GNU Lesser General Public License as published by
12  * the Free Software Foundation; either version 2.1 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU Lesser General Public License for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * along with this program; if not, write to the Free Software Foundation,
22  * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
23  *****************************************************************************/
24 
25 #ifndef _PLAYLIST_FETCHER_H
26 #define _PLAYLIST_FETCHER_H 1
27 
28 #include <vlc_input_item.h>
29 
30 /**
31  * Fetcher opaque structure.
32  *
33  * The fetcher object will retrieve the art album data for any given input
34  * item in an asynchronous way.
35  */
37 
38 /**
39  * This function creates the fetcher object and thread.
40  */
42 
43 /**
44  * This function enqueues the provided item to be art fetched.
45  *
46  * The input item is retained until the art fetching is done or until the
47  * fetcher object is destroyed.
48  */
51 
52 /**
53  * This function destroys the fetcher object and thread.
54  *
55  * All pending input items will be released.
56  */
58 
59 #endif
60 
vlc_dictionary_insert
static void vlc_dictionary_insert(vlc_dictionary_t *p_dict, const char *psz_key, void *p_value)
Definition: vlc_arrays.h:566
playlist_FindArtInCacheUsingItemUID
int playlist_FindArtInCacheUsingItemUID(input_item_t *p_item)
Definition: art.c:230
playlist_t
Structure containing information about the playlist.
Definition: vlc_playlist.h:151
PLAYLIST_PAUSE
No arg.
Definition: vlc_playlist.h:228
playlist_CurrentPlayingItem
playlist_item_t * playlist_CurrentPlayingItem(playlist_t *p_playlist)
Definition: engine.c:484
input_item_t::p_meta
vlc_meta_t * p_meta
Definition: vlc_input_item.h:80
background_worker_New
struct background_worker * background_worker_New(void *owner, struct background_worker_config *conf)
Create a background-worker.
Definition: background_worker.c:184
playlist_fetcher_Push
int playlist_fetcher_Push(playlist_fetcher_t *fetcher, input_item_t *item, input_item_meta_request_option_t options, int preparse_status)
This function enqueues the provided item to be art fetched.
Definition: fetcher.c:450
VIDEO_ES
Definition: vlc_es.h:566
playlist_Create
playlist_t * playlist_Create(vlc_object_t *p_parent)
Create playlist.
Definition: engine.c:195
vlc_memstream
Definition: vlc_memstream.h:27
get_current_status_node
playlist_item_t * get_current_status_node(playlist_t *p_playlist)
Definition: engine.c:404
playlist_SaveArt
int playlist_SaveArt(vlc_object_t *obj, input_item_t *p_item, const void *data, size_t length, const char *psz_type)
Definition: art.c:267
background_worker_RequestProbe
void background_worker_RequestProbe(struct background_worker *worker)
Request the background-worker to probe the current task.
Definition: background_worker.c:250
vlc_meta_Get
const char * vlc_meta_Get(const vlc_meta_t *p_meta, vlc_meta_type_t meta_type)
Definition: meta.c:131
var_SetAddress
#define var_SetAddress(o, n, p)
Definition: vlc_variables.h:260
playlist_private_t::lock
vlc_mutex_t lock
dah big playlist global lock
Definition: playlist_internal.h:82
playlist_CurrentInputLocked
input_thread_t * playlist_CurrentInputLocked(playlist_t *p_playlist)
Get current playing input.
Definition: engine.c:369
background_worker.h
vlc_http.h
playlist_NodeCreate
playlist_item_t * playlist_NodeCreate(playlist_t *p_playlist, const char *psz_name, playlist_item_t *p_parent, int i_pos, int i_flags)
Create a playlist node.
Definition: tree.c:56
input_Control
int input_Control(input_thread_t *p_input, int i_query,...)
Control function for inputs.
Definition: control.c:52
meta_fetcher_t::p_item
input_item_t * p_item
Definition: vlc_meta_fetcher.h:34
META_REQUEST_OPTION_SCOPE_NETWORK
Definition: vlc_input_item.h:366
fetcher_thread::interrupt
vlc_interrupt_t interrupt
Definition: fetcher.c:67
fetcher.h
FETCHER_SCOPE_LOCAL
Definition: vlc_meta_fetcher.h:43
vlc_meta_Album
Definition: vlc_meta.h:39
vlc_memstream::ptr
char * ptr
Definition: vlc_memstream.h:51
vlc_input_item.h
vlc_memstream::error
int error
Definition: vlc_memstream.h:66
vlc_common.h
playlist_t::current
playlist_item_array_t current
Items currently being played.
Definition: vlc_playlist.h:157
playlist_item_t
playlist item / node
Definition: vlc_playlist.h:126
input_item_SetArtFetched
void input_item_SetArtFetched(input_item_t *p_i, bool b_art_fetched)
Definition: item.c:125
playlist_Lock
void playlist_Lock(playlist_t *pl)
Locks the playlist.
Definition: control.c:35
InvokeModule
static int InvokeModule(playlist_fetcher_t *fetcher, input_item_t *item, int scope, char const *type)
Definition: fetcher.c:145
vlc_meta_fetcher.h
VLC_VAR_DOINHERIT
#define VLC_VAR_DOINHERIT
Creation flag.
Definition: vlc_variables.h:69
VLC_THREAD_PRIORITY_LOW
#define VLC_THREAD_PRIORITY_LOW
Definition: vlc_threads.h:321
fetcher_thread
Definition: fetcher.c:60
vlc_memstream::length
size_t length
Definition: vlc_memstream.h:52
PL_LOCK
#define PL_LOCK
Definition: vlc_playlist.h:216
vlc_interrupt.h
input_item_t
Describes an input and is used to spawn input_thread_t objects.
Definition: vlc_input_item.h:58
vlc_dictionary_t
Definition: vlc_arrays.h:386
get_current_status_item
playlist_item_t * get_current_status_item(playlist_t *p_playlist)
Accessor for status item and status nodes.
Definition: engine.c:397
PL_UNLOCK
#define PL_UNLOCK
Definition: vlc_playlist.h:217
vlc_dictionary_clear
static void vlc_dictionary_clear(vlc_dictionary_t *p_dict, void(*pf_free)(void *p_data, void *p_obj), void *p_obj)
Definition: vlc_arrays.h:407
FreeCacheEntry
static void FreeCacheEntry(void *data, void *obj)
Definition: fetcher.c:100
playlist_fetcher_New
playlist_fetcher_t * playlist_fetcher_New(vlc_object_t *)
This function creates the fetcher object and thread.
Definition: fetcher.c:416
background_worker_config::default_timeout
vlc_tick_t default_timeout
Default timeout for completing a task.
Definition: background_worker.h:44
input_item_SetArtURL
#define input_item_SetArtURL
Definition: vlc_input_item.h:314
playlist_fetcher_t::downloader
struct background_worker * downloader
Definition: fetcher.c:64
input_item_t::lock
vlc_mutex_t lock
Lock for the item.
Definition: vlc_input_item.h:93
RandomCallback
static int RandomCallback(vlc_object_t *p_this, char const *psz_cmd, vlc_value_t oldval, vlc_value_t newval, void *a)
Definition: engine.c:44
fetcher_request
Definition: fetcher.c:53
playlist_t::root
playlist_item_t root
Definition: vlc_playlist.h:161
RateCallback
static int RateCallback(vlc_object_t *p_this, char const *psz_cmd, vlc_value_t oldval, vlc_value_t newval, void *p)
Definition: engine.c:115
PLAYLIST_DELETE_FORCE
#define PLAYLIST_DELETE_FORCE
delete node even if read-only
Definition: playlist_internal.h:143
playlist_t::i_current_index
int i_current_index
Index in current array.
Definition: vlc_playlist.h:158
PLAYLIST_RESUME
No arg.
Definition: vlc_playlist.h:229
playlist_item_t::i_nb_played
unsigned i_nb_played
Times played.
Definition: vlc_playlist.h:133
fetcher_thread::req
struct fetcher_request * req
Definition: fetcher.c:64
resource.h
vlc_renderer_item_release
void vlc_renderer_item_release(vlc_renderer_item_t *p_item)
Releases a renderer item, i.e.
Definition: renderer_discovery.c:166
vlc_value_t::p_address
void * p_address
Definition: vlc_common.h:335
var_InheritBool
#define var_InheritBool(o, n)
Definition: vlc_variables.h:601
input_resource_GetAout
audio_output_t * input_resource_GetAout(input_resource_t *p_resource)
This function creates or recycles an audio output.
Definition: resource.c:334
ResetCurrentlyPlaying
void ResetCurrentlyPlaying(playlist_t *p_playlist, playlist_item_t *p_cur)
Reset the currently playing playlist.
Definition: thread.c:143
VLC_VAR_BOOL
#define VLC_VAR_BOOL
Definition: vlc_variables.h:49
playlist_private_t::p_item
playlist_item_t * p_item
Currently playing/active item.
Definition: playlist_internal.h:64
playlist_private_t
Definition: playlist_internal.h:46
playlist_Deactivate
void playlist_Deactivate(playlist_t *p_playlist)
Stops the playlist forever (but do not destroy it yet).
Definition: thread.c:65
playlist_MLDump
int playlist_MLDump(playlist_t *p_playlist)
Definition: loadsave.c:177
playlist_item_t::i_children
int i_children
Number of children, -1 if not a node.
Definition: vlc_playlist.h:132
msg_Dbg
#define msg_Dbg(p_this,...)
Definition: vlc_messages.h:86
playlist_fetcher_t::network
struct background_worker * network
Definition: fetcher.c:63
PLAYLIST_RUNNING
Definition: vlc_playlist.h:148
vlc_stream_NewURL
#define vlc_stream_NewURL(a, b)
Definition: vlc_stream.h:404
_
#define _(str)
Definition: vlc_fixups.h:371
set_current_status_node
void set_current_status_node(playlist_t *p_playlist, playlist_item_t *p_node)
Definition: engine.c:419
vlc_threads.h
VLC_EGENERIC
#define VLC_EGENERIC
Unspecified error.
Definition: vlc_common.h:354
VLC_VAR_ADDRESS
#define VLC_VAR_ADDRESS
Definition: vlc_variables.h:53
ARRAY_SIZE
#define ARRAY_SIZE(x)
Definition: vlc_arrays.h:162
vlc_clone
int vlc_clone(vlc_thread_t *th, void *(*entry)(void *), void *data, int priority)
Creates and starts a new thread.
Definition: thread.c:263
FETCHER_SCOPE_NETWORK
Definition: vlc_meta_fetcher.h:44
VLC_VAR_INTEGER
#define VLC_VAR_INTEGER
Definition: vlc_variables.h:50
VLC_VAR_STRING
#define VLC_VAR_STRING
Definition: vlc_variables.h:51
CorksCallback
static int CorksCallback(vlc_object_t *obj, char const *var, vlc_value_t old, vlc_value_t cur, void *dummy)
When there are one or more pending corks, playback should be paused.
Definition: engine.c:78
VLC_VAR_FLOAT
#define VLC_VAR_FLOAT
Definition: vlc_variables.h:52
input_item_SetPreparsed
void input_item_SetPreparsed(input_item_t *p_i, bool b_preparsed)
Definition: item.c:75
background_worker_config
Definition: background_worker.h:21
vlc_cond_signal
void vlc_cond_signal(vlc_cond_t *p_condvar)
Wakes up one thread waiting on a condition variable.
Definition: thread.c:256
ARRAY_RESET
#define ARRAY_RESET(array)
Definition: vlc_arrays.h:180
var_InheritString
#define var_InheritString(o, n)
Definition: vlc_variables.h:639
playlist_private_t::p_input_resource
input_resource_t * p_input_resource
input resources
Definition: playlist_internal.h:59
asprintf
int asprintf(char **, const char *,...)
fetcher_request::preparse_status
int preparse_status
Definition: fetcher.c:56
vlc_value_t::i_int
int64_t i_int
Definition: vlc_common.h:331
var_Create
#define var_Create(a, b, c)
Definition: vlc_variables.h:121
vlc_memstream_open
int vlc_memstream_open(struct vlc_memstream *ms)
Definition: memstream.c:104
vlc_renderer_discovery.h
playlist_Control
void playlist_Control(playlist_t *p_playlist, int query, int locked,...)
Do a playlist action.
Definition: control.c:139
playlist_fetcher_Delete
void playlist_fetcher_Delete(playlist_fetcher_t *)
This function destroys the fetcher object and thread.
Definition: fetcher.c:472
vlc_meta_Title
Definition: vlc_meta.h:35
var_GetFloat
#define var_GetFloat(a, b)
Definition: vlc_variables.h:657
input_item_SetArtNotFound
void input_item_SetArtNotFound(input_item_t *p_i, bool b_not_found)
Definition: item.c:106
vlc_object_hold
#define vlc_object_hold(a)
Definition: vlc_objects.h:60
playlist_ServicesDiscoveryAdd
int playlist_ServicesDiscoveryAdd(playlist_t *playlist, const char *chain)
Add a service discovery module.
Definition: services_discovery.c:112
vlc_killed
bool vlc_killed(void)
Checks if the interruption context was "killed".
Definition: interrupt.c:186
ResyncCurrentIndex
void ResyncCurrentIndex(playlist_t *p_playlist, playlist_item_t *p_cur)
Synchronise the current index of the playlist to match the index of the current item.
Definition: thread.c:117
input_item_GetArtURL
#define input_item_GetArtURL
Definition: vlc_input_item.h:315
vlc_http_cookies_new
vlc_http_cookie_jar_t * vlc_http_cookies_new(void)
Definition: httpcookies.c:272
VLC_VAR_VOID
#define VLC_VAR_VOID
Definition: vlc_variables.h:48
audio_output
Audio output object.
Definition: vlc_aout.h:114
vlc_value_t::b_bool
bool b_bool
Definition: vlc_common.h:332
playlist_fetcher_t
Definition: fetcher.c:43
playlist_private_t::p_renderer
vlc_renderer_item_t * p_renderer
Definition: playlist_internal.h:60
ReadAlbumCache
static int ReadAlbumCache(playlist_fetcher_t *fetcher, input_item_t *item)
Definition: fetcher.c:106
vlc_object_release
#define vlc_object_release(a)
Definition: vlc_objects.h:63
interrupt.h
vlc_interrupt_kill
void vlc_interrupt_kill(vlc_interrupt_t *ctx)
Marks the interruption context as "killed".
Definition: interrupt.c:178
RequestHold
static void RequestHold(void *req_)
Definition: fetcher.c:330
vlc_meta_Artist
Definition: vlc_meta.h:36
playlist_private_t::status
struct playlist_private_t::@74 status
background_worker
Definition: background_worker.c:37
playlist_Destroy
void playlist_Destroy(playlist_t *p_playlist)
Destroy playlist.
Definition: engine.c:311
module_t
Internal module descriptor.
Definition: modules.h:79
SearchNetwork
static void SearchNetwork(playlist_fetcher_t *fetcher, struct fetcher_request *req)
Definition: fetcher.c:310
input_item_SignalPreparseEnded
void input_item_SignalPreparseEnded(input_item_t *p_i, int new_status)
Definition: item.c:68
fetcher_request::item
input_item_t * item
Definition: fetcher.c:54
ARRAY_INIT
#define ARRAY_INIT(array)
Definition: vlc_arrays.h:173
vlc_value_t::f_float
float f_float
Definition: vlc_common.h:333
vlc_atomic.h
vlc_memstream.h
PLAYLIST_PAUSED
Definition: vlc_playlist.h:148
playlist_ServicesDiscoveryKillAll
void playlist_ServicesDiscoveryKillAll(playlist_t *p_playlist)
Definition: services_discovery.c:246
input_resource_Release
void input_resource_Release(input_resource_t *p_resource)
It releases an input resource.
Definition: resource.c:430
vlc_dictionary_value_for_key
static void * vlc_dictionary_value_for_key(const vlc_dictionary_t *p_dict, const char *psz_key)
Definition: vlc_arrays.h:450
vlc_meta_ArtworkURL
Definition: vlc_meta.h:51
StartSearchNetwork
static int StartSearchNetwork(void *fetcher_, void *req_, void **out)
Definition: fetcher.c:399
vlc_interface.h
background_worker_Push
int background_worker_Push(struct background_worker *worker, void *entity, void *id, int timeout)
Push an entity into the background-worker.
Definition: background_worker.c:208
var_Destroy
#define var_Destroy(a, b)
Definition: vlc_variables.h:124
var_SetFloat
#define var_SetFloat(a, b, c)
Definition: vlc_variables.h:258
StartDownloader
static int StartDownloader(void *fetcher_, void *req_, void **out)
Definition: fetcher.c:400
meta_fetcher_t::e_scope
meta_fetcher_scope_t e_scope
Definition: vlc_meta_fetcher.h:35
AddAlbumCache
static void AddAlbumCache(playlist_fetcher_t *fetcher, input_item_t *item, bool overwrite)
Definition: fetcher.c:124
meta_fetcher_t
Definition: vlc_meta_fetcher.h:31
vlc_interrupt_set
vlc_interrupt_t * vlc_interrupt_set(vlc_interrupt_t *newctx)
Sets the interruption context for the calling thread.
Definition: interrupt.c:99
VLC_VAR_ISCOMMAND
#define VLC_VAR_ISCOMMAND
Definition: vlc_variables.h:64
PAUSE_S
Definition: vlc_input.h:285
input_item_meta_request_option_t
input_item_meta_request_option_t
Definition: vlc_input_item.h:362
playlist_internal.h
PLAYLIST_NO_INHERIT_FLAG
Will children inherit flags the R/O flag ?
Definition: vlc_playlist.h:143
vlc_thread_t
Thread handle.
Definition: vlc_threads.h:252
StartWorker
static int StartWorker(playlist_fetcher_t *fetcher, void(*pf_worker)(playlist_fetcher_t *, struct fetcher_request *), struct background_worker *bg, struct fetcher_request *req, void **handle)
Definition: fetcher.c:348
PL_ASSERT_LOCKED
#define PL_ASSERT_LOCKED
Definition: vlc_playlist.h:218
vlc_mutex_init
void vlc_mutex_init(vlc_mutex_t *p_mutex)
Initializes a fast mutex.
Definition: thread.c:85
vlc_interrupt_deinit
void vlc_interrupt_deinit(vlc_interrupt_t *ctx)
Deinitializes an interruption context.
Definition: interrupt.c:71
playlist_FindArtInCache
int playlist_FindArtInCache(input_item_t *p_item)
Definition: art.c:161
WorkerInit
static void WorkerInit(playlist_fetcher_t *fetcher, struct background_worker **worker, int(*starter)(void *, void *, void **))
Definition: fetcher.c:402
stream_t
stream_t definition
Definition: vlc_stream.h:46
var_GetInteger
#define var_GetInteger(a, b)
Definition: vlc_variables.h:655
playlist_fetcher_t::owner
vlc_object_t * owner
Definition: fetcher.c:67
PLAYLIST_RO_FLAG
Write-enabled ?
Definition: vlc_playlist.h:141
fetcher_thread::fetcher
playlist_fetcher_t * fetcher
Definition: fetcher.c:65
input_item_Release
void input_item_Release(input_item_t *p_item)
Releases an input item, i.e.
Definition: item.c:477
playlist_CurrentInput
input_thread_t * playlist_CurrentInput(playlist_t *p_playlist)
Get current playing input.
Definition: engine.c:382
StartSearchLocal
static int StartSearchLocal(void *fetcher_, void *req_, void **out)
Definition: fetcher.c:398
FetcherThread
static void * FetcherThread(void *handle)
Definition: fetcher.c:336
vlc_interrupt
Definition: interrupt.h:30
vlc_stream_Read
ssize_t vlc_stream_Read(stream_t *s, void *buf, size_t len)
Reads data from a byte stream.
Definition: stream.c:453
VariablesInit
static void VariablesInit(playlist_t *p_playlist)
Definition: engine.c:427
INPUT_RESTART_ES
Definition: vlc_input.h:467
ProbeWorker
static int ProbeWorker(void *fetcher_, void *th_)
Definition: fetcher.c:376
playlist_NodeDeleteExplicit
void playlist_NodeDeleteExplicit(playlist_t *, playlist_item_t *, int flags)
Delete a node with explicit semantics.
Definition: tree.c:96
vlc_sout.h
art.h
playlist_item_t::i_id
int i_id
Playlist item specific id.
Definition: vlc_playlist.h:135
CheckMeta
static int CheckMeta(input_item_t *item)
Definition: fetcher.c:166
vlc_dictionary_has_key
static int vlc_dictionary_has_key(const vlc_dictionary_t *p_dict, const char *psz_key)
Definition: vlc_arrays.h:434
playlist_fetcher_t::album_cache
vlc_dictionary_t album_cache
Definition: fetcher.c:66
likely
#define likely(p)
Definition: vlc_common.h:113
SearchLocal
static void SearchLocal(playlist_fetcher_t *fetcher, struct fetcher_request *req)
Definition: fetcher.c:292
vlc_object_t
The main vlc_object_t structure.
Definition: vlc_objects.h:39
VLC_ENOMEM
#define VLC_ENOMEM
Not enough memory.
Definition: vlc_common.h:355
background_worker_Delete
void background_worker_Delete(struct background_worker *worker)
Delete a background-worker.
Definition: background_worker.c:258
fetcher_thread::worker
struct background_worker * worker
Definition: fetcher.c:63
fetcher_thread::pf_worker
void(* pf_worker)(playlist_fetcher_t *, struct fetcher_request *)
Definition: fetcher.c:61
VLC_UNUSED
#define VLC_UNUSED(x)
Definition: vlc_common.h:916
set_current_status_item
void set_current_status_item(playlist_t *p_playlist, playlist_item_t *p_item)
Definition: engine.c:411
vlc_stream.h
playlist_fetcher_t::lock
vlc_mutex_t lock
Definition: fetcher.c:68
vlc_mutex_t
pthread_mutex_t vlc_mutex_t
Mutex.
Definition: vlc_threads.h:267
input_interface.h
VLC_SUCCESS
#define VLC_SUCCESS
No error.
Definition: vlc_common.h:353
SearchArt
static int SearchArt(playlist_fetcher_t *fetcher, input_item_t *item, int scope)
Definition: fetcher.c:186
playlist_private_t::signal
vlc_cond_t signal
wakes up the playlist engine thread
Definition: playlist_internal.h:83
FREENULL
#define FREENULL(a)
Definition: vlc_common.h:770
fetcher_thread::active
atomic_bool active
Definition: fetcher.c:69
playlist_item_t::i_flags
uint8_t i_flags
Flags.
Definition: vlc_playlist.h:136
vlc_custom_create
#define vlc_custom_create(o, s, n)
Definition: libvlc.h:108
vlc_http_cookies_destroy
void vlc_http_cookies_destroy(vlc_http_cookie_jar_t *p_jar)
Definition: httpcookies.c:284
RateOffsetCallback
static int RateOffsetCallback(vlc_object_t *obj, char const *psz_cmd, vlc_value_t oldval, vlc_value_t newval, void *p_data)
Definition: engine.c:130
var_GetAddress
#define var_GetAddress(a, b)
Definition: vlc_variables.h:660
PLAYLIST_END
#define PLAYLIST_END
Definition: vlc_playlist.h:204
playlist_Activate
void playlist_Activate(playlist_t *)
Creates the main playlist thread.
Definition: thread.c:48
vlc_cond_destroy
void vlc_cond_destroy(vlc_cond_t *p_condvar)
Deinitializes a condition variable.
Definition: thread.c:228
vlc_cond_init
void vlc_cond_init(vlc_cond_t *p_condvar)
Initializes a condition variable.
Definition: thread.c:216
TAB_INIT
#define TAB_INIT(count, tab)
Definition: vlc_arrays.h:40
fetcher_request::refs
atomic_uint refs
Definition: fetcher.c:55
playlist_Status
int playlist_Status(playlist_t *p_playlist)
Definition: engine.c:491
input_resource_New
input_resource_t * input_resource_New(vlc_object_t *p_parent)
It creates an empty input resource handler.
Definition: resource.c:417
vlc_mutex_destroy
void vlc_mutex_destroy(vlc_mutex_t *p_mutex)
Deinitializes a mutex.
Definition: thread.c:110
playlist_fetcher_Push
int playlist_fetcher_Push(playlist_fetcher_t *, input_item_t *, input_item_meta_request_option_t, int)
This function enqueues the provided item to be art fetched.
Definition: fetcher.c:450
playlist_private_t::p_input
input_thread_t * p_input
the input thread associated with the current item
Definition: playlist_internal.h:57
playlist_fetcher_New
playlist_fetcher_t * playlist_fetcher_New(vlc_object_t *owner)
This function creates the fetcher object and thread.
Definition: fetcher.c:416
vlc_memstream_write
size_t vlc_memstream_write(struct vlc_memstream *ms, const void *ptr, size_t len)
Definition: memstream.c:126
vlc_mutex_unlock
void vlc_mutex_unlock(vlc_mutex_t *p_mutex)
Releases a mutex.
Definition: thread.c:138
Downloader
static void Downloader(playlist_fetcher_t *fetcher, struct fetcher_request *req)
Definition: fetcher.c:226
fetcher_thread::thread
vlc_thread_t thread
Definition: fetcher.c:68
unlikely
#define unlikely(p)
Definition: vlc_common.h:114
pl_priv
#define pl_priv(pl)
Definition: playlist_internal.h:103
var_AddCallback
#define var_AddCallback(a, b, c, d)
Definition: vlc_variables.h:164
playlist_t::p_playing
playlist_item_t * p_playing
Definition: vlc_playlist.h:162
playlist_fetcher_Delete
void playlist_fetcher_Delete(playlist_fetcher_t *fetcher)
This function destroys the fetcher object and thread.
Definition: fetcher.c:472
SetPreparsed
static void SetPreparsed(struct fetcher_request *req)
Definition: fetcher.c:217
CloseWorker
static void CloseWorker(void *fetcher_, void *th_)
Definition: fetcher.c:382
input_resource_PutAout
void input_resource_PutAout(input_resource_t *p_resource, audio_output_t *p_aout)
This function retains or destroys an audio output.
Definition: resource.c:366
fetcher_request::options
int options
Definition: fetcher.c:57
libvlc.h
var_SetChecked
#define var_SetChecked(o, n, t, v)
Definition: vlc_variables.h:139
vlc_dictionary_init
static void vlc_dictionary_init(vlc_dictionary_t *p_dict, int i_size)
Definition: vlc_arrays.h:394
vlc_playlist.h
playlist_item_t::pp_children
playlist_item_t ** pp_children
Children nodes/items.
Definition: vlc_playlist.h:130
playlist_t::p_media_library
playlist_item_t * p_media_library
Definition: vlc_playlist.h:163
PLAYLIST_STOPPED
Definition: vlc_playlist.h:148
playlist_MLLoad
int playlist_MLLoad(playlist_t *p_playlist)
Definition: loadsave.c:128
playlist_Unlock
void playlist_Unlock(playlist_t *pl)
Unlocks the playlist.
Definition: control.c:40
strsep
char * strsep(char **, const char *)
vlc_arrays.h
vlc_interrupt_init
void vlc_interrupt_init(vlc_interrupt_t *ctx)
Initializes an interruption context.
Definition: interrupt.c:51
input_thread_t
Main structure representing an input thread.
Definition: vlc_input.h:221
VLC_OBJECT
#define VLC_OBJECT(x)
Type-safe vlc_object_t cast.
Definition: vlc_common.h:468
playlist_t::items
playlist_item_array_t items
Arrays of items.
Definition: vlc_playlist.h:155
input_item_Hold
input_item_t * input_item_Hold(input_item_t *p_item)
Holds an input item, i.e.
Definition: item.c:469
module_unneed
#define module_unneed(a, b)
Definition: vlc_modules.h:49
RequestRelease
static void RequestRelease(void *req_)
Definition: fetcher.c:319
vlc_value_t
VLC value structure.
Definition: vlc_common.h:329
playlist_fetcher_t::local
struct background_worker * local
Definition: fetcher.c:62
CreateCacheKey
static char * CreateCacheKey(input_item_t *item)
Definition: fetcher.c:72
SearchByScope
static int SearchByScope(playlist_fetcher_t *fetcher, struct fetcher_request *req, int scope)
Definition: fetcher.c:192
VideoSplitterCallback
static int VideoSplitterCallback(vlc_object_t *p_this, char const *psz_cmd, vlc_value_t oldval, vlc_value_t newval, void *p_data)
Definition: engine.c:167
vlc_mutex_lock
void vlc_mutex_lock(vlc_mutex_t *p_mutex)
Acquires a mutex.
Definition: thread.c:123
pl_Locked
Definition: vlc_playlist.h:208
vlc_memstream_close
int vlc_memstream_close(struct vlc_memstream *ms)
Definition: memstream.c:119
CheckArt
static int CheckArt(input_item_t *item)
Definition: fetcher.c:177
DEF_STARTER
#define DEF_STARTER(name, worker)
Definition: fetcher.c:393
playlist_item_t::p_input
input_item_t * p_input
Linked input item.
Definition: vlc_playlist.h:128
vlc_join
void vlc_join(vlc_thread_t handle, void **result)
Waits for a thread to complete (if needed), then destroys it.
Definition: thread.c:270
module_need
#define module_need(a, b, c, d)
Definition: vlc_modules.h:47
p
#define p(t)
vlc_modules.h
vlc_stream_Delete
void vlc_stream_Delete(stream_t *s)
Destroy a stream.
Definition: stream.c:120