50 #ifndef FFmpegVideoProvider_H_
51 #define FFmpegVideoProvider_H_
55 #include "mb/interface/IContinuousMediaProvider.h"
56 #include "mb/interface/dfb/content/audio/FusionSoundAudioProvider.h"
57 using namespace ::br::pucrio::telemidia::ginga::core::mb;
60 #define INT64_C(c) (c ## LL)
61 #define UINT64_C(c) (c ## ULL)
73 #include <sys/types.h>
84 #include <direct/types.h>
85 #include <direct/list.h>
86 #include <direct/messages.h>
87 #include <direct/memcpy.h>
88 #include <direct/thread.h>
89 #include <direct/util.h>
94 #include "fusionsound/fusionsound_limits.h"
96 #include "libavutil/common.h"
97 #include "libavcodec/avcodec.h"
98 #include "libavformat/avformat.h"
113 pthread_mutex_t lock;
118 IDirectFBEventBuffer *buffer;
124 DFBVideoProviderStatus status;
125 DFBVideoProviderPlaybackFlags flags;
133 IDirectFBDataBuffer *buffer;
138 AVFormatContext* context;
143 DirectThread *thread;
144 pthread_mutex_t lock;
154 DirectThread *thread;
155 pthread_mutex_t lock;
170 IDirectFBSurface *dest;
174 DVCColormap *colormap;
179 DirectThread *thread;
180 pthread_mutex_t lock;
194 IFusionSoundStream *stream;
195 IFusionSoundPlayback *playback;
203 DVFrameCallback callback;
208 #define IO_BUFFER_SIZE 8
210 #define MAX_QUEUE_LEN 3
212 #define GAP_TOLERANCE 15000
214 #define GAP_THRESHOLD 250000
223 namespace telemidia {
230 GingaScreenID myScreen;
233 static bool _ffmpegInitialized;
235 bool getHasVisual(){
return true;};
242 bool initializeFFmpeg(
const char* mrl);
245 void setLoadSymbol(
string symbol);
246 string getLoadSymbol();
248 void setAVPid(
int aPid,
int vPid);
249 void* getProviderContent();
250 void setProviderContent(
void* content){};
254 void getVideoSurfaceDescription(DFBSurfaceDescription* dsc);
255 IDirectFBSurface* getPerfectDFBSurface();
260 void getOriginalResolution(
int* width,
int* height);
261 double getTotalMediaTime();
263 double getMediaTime();
264 void setMediaTime(
double pos);
267 bool updateVisualData(
ISurface* surface);
270 static void dynamicRenderCallBack(
void* surface);
275 void resume(
ISurface* surface,
bool hasVisual=
true);
278 void setSoundLevel(
float level);
280 void refreshDR(
void* data){};
Definition: FFmpegVideoProvider.h:116
Definition: NetworkUtil.h:53
Definition: IContinuousMediaProvider.h:71
Definition: IProviderListener.h:59
Definition: FFmpegVideoProvider.h:108
Definition: FFmpegVideoProvider.h:121
Definition: FFmpegVideoProvider.h:227
Definition: FFmpegVideoProvider.h:103
Definition: ISurface.h:64