14 #include <epan/epan.h> 15 #include "ws_symbol_export.h" 16 #include "ws_attributes.h" 18 #include "wsutil/plugins.h" 27 void (*register_codec_module)(void);
30 WS_DLL_PUBLIC
void codecs_register_plugin(
const codecs_plugin *plug);
36 WS_DLL_PUBLIC
void codecs_init(
void);
38 WS_DLL_PUBLIC
void codecs_cleanup(
void);
43 WS_DLL_PUBLIC
void codec_get_compiled_version_info(GString *str);
48 typedef void *(*codec_init_fn)(void);
49 typedef void (*codec_release_fn)(
void *context);
50 typedef unsigned (*codec_get_channels_fn)(
void *context);
51 typedef unsigned (*codec_get_frequency_fn)(
void *context);
52 typedef size_t (*codec_decode_fn)(
void *context,
const void *input,
size_t inputSizeBytes,
53 void *output,
size_t *outputSizeBytes);
55 WS_DLL_PUBLIC gboolean register_codec(
const char *name, codec_init_fn init_fn,
56 codec_release_fn release_fn, codec_get_channels_fn channels_fn,
57 codec_get_frequency_fn frequency_fn, codec_decode_fn decode_fn);
58 WS_DLL_PUBLIC gboolean deregister_codec(
const char *name);
59 WS_DLL_PUBLIC codec_handle_t find_codec(
const char *name);
60 WS_DLL_PUBLIC
void *codec_init(codec_handle_t codec);
61 WS_DLL_PUBLIC
void codec_release(codec_handle_t codec,
void *context);
62 WS_DLL_PUBLIC
unsigned codec_get_channels(codec_handle_t codec,
void *context);
63 WS_DLL_PUBLIC
unsigned codec_get_frequency(codec_handle_t codec,
void *context);
64 WS_DLL_PUBLIC
size_t codec_decode(codec_handle_t codec,
void *context,
const void *input,
65 size_t inputSizeBytes,
void *output,
size_t *outputSizeBytes);