3 // Andrew Bachmann, 2002
5 // A MediaReaderAddOn is an add-on
6 // that can make MediaReader nodes
8 // MediaReader nodes read a file into a multistream
10 #if !defined(_MEDIA_READER_ADD_ON_H)
11 #define _MEDIA_READER_ADD_ON_H
13 #include <MediaDefs.h>
14 #include <MediaAddOn.h>
15 #include "../AbstractFileInterfaceAddOn.h"
17 class MediaReaderAddOn
:
18 public AbstractFileInterfaceAddOn
21 virtual ~MediaReaderAddOn(void);
22 explicit MediaReaderAddOn(image_id image
);
24 /**************************/
25 /* begin from BMediaAddOn */
27 virtual status_t
GetFlavorAt(
29 const flavor_info
** out_info
);
30 virtual BMediaNode
* InstantiateNodeFor(
31 const flavor_info
* info
,
33 status_t
* out_error
);
34 virtual status_t
GetConfigurationFor(
35 BMediaNode
* your_node
,
36 BMessage
* into_message
);
38 /* only implement if you have a B_FILE_INTERFACE node */
39 virtual status_t
GetFileFormatList(
40 int32 flavor_id
, // for this node flavor (if it matters)
41 media_file_format
* out_writable_formats
, // don't write here if NULL
42 int32 in_write_items
, // this many slots in out_writable_formats
43 int32
* out_write_items
, // set this to actual # available, even if bigger than in count
44 media_file_format
* out_readable_formats
, // don't write here if NULL
45 int32 in_read_items
, // this many slots in out_readable_formats
46 int32
* out_read_items
, // set this to actual # available, even if bigger than in count
47 void * _reserved
); // ignore until further notice
49 using AbstractFileInterfaceAddOn::SniffTypeKind
;
51 virtual status_t
SniffTypeKind( // Like SniffType, but for the specific kind(s)
52 const BMimeType
& type
,
55 int32
* out_internal_id
,
58 /* end from BMediaAddOn */
59 /************************/
63 MediaReaderAddOn( /* private unimplemented */
64 const MediaReaderAddOn
& clone
);
65 MediaReaderAddOn
& operator=(
66 const MediaReaderAddOn
& clone
);
69 virtual status_t
_Reserved_MediaReaderAddOn_0(void *);
70 virtual status_t
_Reserved_MediaReaderAddOn_1(void *);
71 virtual status_t
_Reserved_MediaReaderAddOn_2(void *);
72 virtual status_t
_Reserved_MediaReaderAddOn_3(void *);
73 virtual status_t
_Reserved_MediaReaderAddOn_4(void *);
74 virtual status_t
_Reserved_MediaReaderAddOn_5(void *);
75 virtual status_t
_Reserved_MediaReaderAddOn_6(void *);
76 virtual status_t
_Reserved_MediaReaderAddOn_7(void *);
77 virtual status_t
_Reserved_MediaReaderAddOn_8(void *);
78 virtual status_t
_Reserved_MediaReaderAddOn_9(void *);
79 virtual status_t
_Reserved_MediaReaderAddOn_10(void *);
80 virtual status_t
_Reserved_MediaReaderAddOn_11(void *);
81 virtual status_t
_Reserved_MediaReaderAddOn_12(void *);
82 virtual status_t
_Reserved_MediaReaderAddOn_13(void *);
83 virtual status_t
_Reserved_MediaReaderAddOn_14(void *);
84 virtual status_t
_Reserved_MediaReaderAddOn_15(void *);
86 uint32 _reserved_media_reader_add_on_
[16];
90 #if BUILDING_MEDIA_READER__ADD_ON
91 extern "C" _EXPORT BMediaAddOn
* make_media_reader_add_on(image_id you
);
94 #endif /* _MEDIA_READER_ADD_ON_H */