#ifndef SERVICEWINDOWGENERATIONFROMSRT_H #define SERVICEWINDOWGENERATIONFROMSRT_H #include "serviceWindowGeneration.h" #include #include "inputFile.h" #include "extratorSRT.h" #include "listenerSRT.h" #include "stdint.h" #include #include "jthread.h" using namespace std; using namespace jthread; using namespace Util; class ServiceWindowGenerationFromSRT : public ServiceWindowGeneration, public ListenerSRT, public Thread { private: pthread_mutex_t *mutex_serviceSRT; ExtratorSRT * extratorSRT; char* path_srt; bool finish; public: /* Construtor 1 - legenda e vídeo */ ServiceWindowGenerationFromSRT(char* path_video, char* path_srt, int sublanguage, int position, int size, int transparency, char* id, int _serviceType); /* Construtor 2 - só legenda */ ServiceWindowGenerationFromSRT(char* path_srt, int transparency, char* id, int _serviceType); ~ServiceWindowGenerationFromSRT(); virtual void notifySubtitle(unsigned char* subtitle, int64_t pts); virtual void notifyEnd(int sub_size); void notifyTranslator(unsigned char* subtitle); void initialize(); bool isFinished(); void Run(); void setPathSRT(char* path_srt); }; #endif /* SERVICEWINDOWGENERATIONFROMSRT_H */