10#ifndef VLC_PREPARSER_IPC_H
11#define VLC_PREPARSER_IPC_H
111 struct VLC_VECTOR(bool) result;
128 VLC_PREPARSER_MSG_TYPE_REQ,
129 VLC_PREPARSER_MSG_TYPE_RES,
175#define VLC_PREPARSER_MSG_SERDES_TYPE_DATA 0x1
176#define VLC_PREPARSER_MSG_SERDES_TYPE_ATTACHMENT 0x2
177#define VLC_PREPARSER_MSG_SERDES_TYPE_END_DATA 0x4
178#define VLC_PREPARSER_MSG_SERDES_TYPE_END_ATTACHMENT 0x8
190 ssize_t (*write)(
const void *data,
size_t size,
void *userdata);
201 ssize_t (*read)(
void *data,
size_t size,
void *userdata);
259#define set_callback_preparser_msg_serdes(activate, priority) \
261 vlc_preparser_msg_serdes_module open__ = activate;\
263 set_callback(activate)\
265 set_capability("preparser msg serdes", priority)
281 assert(serdes != NULL);
303 assert(serdes!= NULL);
319 assert(serdes != NULL);
321 if (serdes->
ops != NULL && serdes->
ops->
close != NULL) {
#define VLC_API
Definition fourcc_gen.c:31
#define VLC_EGENERIC
Unspecified error.
Definition vlc_common.h:482
void vlc_preparser_msg_Clean(struct vlc_preparser_msg *msg)
Clean all memory used by a message.
Definition ipc.c:104
void vlc_preparser_msg_Init(struct vlc_preparser_msg *msg, int msg_type, enum vlc_preparser_msg_req_type req_type)
Initialize a preparser message.
Definition ipc.c:72
vlc_preparser_msg_req_type
Request types.
Definition vlc_preparser_ipc.h:36
@ VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL_TO_FILES
Type of the request emitted by a vlc_preparser_GenerateThumbnailToFiles call.
Definition vlc_preparser_ipc.h:50
@ VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL
Type of the request emitted by a vlc_preparser_GenerateThumbnail call.
Definition vlc_preparser_ipc.h:45
@ VLC_PREPARSER_MSG_REQ_TYPE_PARSE
Type of the request emitted by a vlc_preparser_Push call.
Definition vlc_preparser_ipc.h:40
struct vlc_preparser_msg_serdes * vlc_preparser_msg_serdes_Create(vlc_object_t *obj, const struct vlc_preparser_msg_serdes_cbs *c, bool bin_data)
Create a vlc_preparser_msg_serdes object and load a preparser msg_serdes module.
Definition ipc.c:32
int(* vlc_preparser_msg_serdes_module)(struct vlc_preparser_msg_serdes *, bool)
Definition vlc_preparser_ipc.h:258
static void vlc_preparser_msg_serdes_Delete(struct vlc_preparser_msg_serdes *serdes)
Free the msg_serdes struct.
Definition vlc_preparser_ipc.h:318
static int vlc_preparser_msg_serdes_Deserialize(struct vlc_preparser_msg_serdes *serdes, struct vlc_preparser_msg *msg, void *userdata)
Call the deserialize operation.
Definition vlc_preparser_ipc.h:300
static int vlc_preparser_msg_serdes_Serialize(struct vlc_preparser_msg_serdes *serdes, const struct vlc_preparser_msg *msg, void *userdata)
Call the serialize operation.
Definition vlc_preparser_ipc.h:278
#define VLC_VECTOR(type)
Vector struct body.
Definition vlc_vector.h:66
static const struct @110 msg_type[]
Video picture.
Definition vlc_picture.h:128
VLC object common members.
Definition vlc_objects.h:53
Preparser request.
Definition vlc_preparser_ipc.h:56
struct vlc_preparser_msg_req::@288 outputs_path
Used only by request of type VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL_TO_FILES.
struct vlc_thumbnailer_arg arg
Used by both type VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL and VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL_TO_FI...
Definition vlc_preparser_ipc.h:71
char * uri
Definition vlc_preparser_ipc.h:84
int options
Used only by request of type VLC_PREPARSER_MSG_REQ_TYPE_PARSE.
Definition vlc_preparser_ipc.h:65
enum vlc_preparser_msg_req_type type
Type of the request.
Definition vlc_preparser_ipc.h:60
struct vlc_preparser_msg_req::@289 outputs
Preparser Response.
Definition vlc_preparser_ipc.h:90
struct vlc_preparser_msg_res::@290 attachments
Used only by request of type VLC_PREPARSER_MSG_REQ_TYPE_PARSE.
input_item_t * item
Definition vlc_preparser_ipc.h:118
enum vlc_preparser_msg_req_type type
Type of the response (As the response answering a request they share the same type).
Definition vlc_preparser_ipc.h:95
input_item_node_t * subtree
Definition vlc_preparser_ipc.h:101
int status
Used by all types of request.
Definition vlc_preparser_ipc.h:117
picture_t * pic
Used only by request of type VLC_PREPARSER_MSG_REQ_TYPE_THUMBNAIL.
Definition vlc_preparser_ipc.h:106
Definition vlc_preparser_ipc.h:181
Definition vlc_preparser_ipc.h:207
int(* deserialize)(struct vlc_preparser_msg_serdes *serdes, struct vlc_preparser_msg *msg, void *userdata)
Deserialize msg and call the read callback to get data to deserialize.
Definition vlc_preparser_ipc.h:230
int(* serialize)(struct vlc_preparser_msg_serdes *serdes, const struct vlc_preparser_msg *msg, void *userdata)
Serialize msg and call the write callback with serialized data.
Definition vlc_preparser_ipc.h:217
void(* close)(struct vlc_preparser_msg_serdes *serdes)
Close the serializer/deserialier and release all used memory.
Definition vlc_preparser_ipc.h:239
Internal structure used by serializer.
Definition vlc_preparser_ipc.h:245
void * sys
Used by the serializer module.
Definition vlc_preparser_ipc.h:253
const struct vlc_preparser_msg_serdes_operations * ops
Operations.
Definition vlc_preparser_ipc.h:247
const struct vlc_preparser_msg_serdes_cbs * cbs
Callbacks.
Definition vlc_preparser_ipc.h:251
Preparser message.
Definition vlc_preparser_ipc.h:124
enum vlc_preparser_msg_req_type req_type
Type of the underling request or response.
Definition vlc_preparser_ipc.h:136
@ VLC_PREPARSER_MSG_TYPE_RES
Definition vlc_preparser_ipc.h:130
@ VLC_PREPARSER_MSG_TYPE_REQ
Definition vlc_preparser_ipc.h:129
Thumbnailer argument.
Definition vlc_preparser.h:193
Thumbnailer output argument.
Definition vlc_preparser.h:242
This file is a collection of common definitions and types.
This file declares interruptible sleep functions.
This provides convenience helpers for vectors.