This source file includes following definitions.
- QueryInterfaces
- LoadInterface
- ShutdownInterface
#include "ffmpeg_in.h"
#if (defined(WIN32) || defined(_WIN32_WCE)) && !defined(__GNUC__)
#if defined(_WIN32_WCE)
#pragma comment(lib, "toolhelp")
#pragma comment(lib, "winsock")
#endif
#define _TOSTR(_val) #_val
#define TOSTR(_val) _TOSTR(_val)
#endif
GPAC_MODULE_EXPORT
const u32 *QueryInterfaces()
{
static u32 si [] = {
GF_MEDIA_DECODER_INTERFACE,
#ifndef DISABLE_FFMPEG_DEMUX
GF_NET_CLIENT_INTERFACE,
#endif
0
};
return si;
}
GPAC_MODULE_EXPORT
GF_BaseInterface *LoadInterface(u32 InterfaceType)
{
if (InterfaceType == GF_MEDIA_DECODER_INTERFACE) return (GF_BaseInterface*)FFDEC_Load();
#ifndef DISABLE_FFMPEG_DEMUX
if (InterfaceType == GF_NET_CLIENT_INTERFACE) return (GF_BaseInterface*)New_FFMPEG_Demux();
#endif
return NULL;
}
GPAC_MODULE_EXPORT
void ShutdownInterface(GF_BaseInterface *ifce)
{
switch (ifce->InterfaceType) {
case GF_MEDIA_DECODER_INTERFACE:
FFDEC_Delete(ifce);
break;
#ifndef DISABLE_FFMPEG_DEMUX
case GF_NET_CLIENT_INTERFACE:
Delete_FFMPEG_Demux(ifce);
break;
#endif
}
}
GPAC_MODULE_STATIC_DECLARATION( ffmpeg )