gets a reader and writer fd, where input is assumed to be an an MPEG PS stream, strips out unwanted streams and writes the remuxed result to the output fd. Uses blocking read/write operations. More...
#include <mpegremux_processor.h>
Public Member Functions | |
| MPEGRemuxProcessor (int in_fd, int out_fd, unsigned char keep_audio_id) | |
| virtual int | getStatus () |
| the exit status of the thread - needs to be overridden | |
| virtual bool | isAlive () |
| method to check if the executor is still running | |
| virtual bool | kill () |
| kill the thread (pthread_join) | |
| void | retain () |
| void | release () |
| int | getRefCount () |
Static Public Member Functions | |
| static void * | operator new (size_t size) |
| static void | operator delete (void *ptr) |
Protected Member Functions | |
| virtual void | threadProc () |
| abstract thread method, which needs to be overridden | |
| void | startThread () |
| start the thread | |
| bool | threadShutdownCheck () |
| check if the thread should shutdown should be called by the threadProc in short intervals | |
Protected Attributes | |
| bool | threadShutdown |
| bool | threadRunning |
| if the thread is currently running | |
| zmm::Ref< Cond > | cond |
| zmm::Ref< Mutex > | mutex |
| mt_atomic_t | _ref_count |
Private Attributes | |
| int | status |
| int | in_fd |
| int | out_fd |
| unsigned char | keep_audio_id |
gets a reader and writer fd, where input is assumed to be an an MPEG PS stream, strips out unwanted streams and writes the remuxed result to the output fd. Uses blocking read/write operations.
Definition at line 48 of file mpegremux_processor.h.
| MPEGRemuxProcessor::MPEGRemuxProcessor | ( | int | in_fd, | |
| int | out_fd, | |||
| unsigned char | keep_audio_id | |||
| ) |
| int Object::getRefCount | ( | ) | [inherited] |
Definition at line 78 of file object.cc.
References zmm::Object::_ref_count, and atomic_get().
| virtual int MPEGRemuxProcessor::getStatus | ( | ) | [inline, virtual] |
the exit status of the thread - needs to be overridden
Implements ThreadExecutor.
Definition at line 52 of file mpegremux_processor.h.
References status.
| virtual bool ThreadExecutor::isAlive | ( | ) | [inline, virtual, inherited] |
method to check if the executor is still running
Implements Executor.
Definition at line 49 of file thread_executor.h.
References ThreadExecutor::threadRunning.
| bool ThreadExecutor::kill | ( | ) | [virtual, inherited] |
kill the thread (pthread_join)
Implements Executor.
Definition at line 64 of file thread_executor.cc.
References AUTOLOCK, AUTOUNLOCK, ThreadExecutor::cond, ThreadExecutor::mutex, NULL, ThreadExecutor::thread, ThreadExecutor::threadRunning, and ThreadExecutor::threadShutdown.
Referenced by ThreadExecutor::~ThreadExecutor().
| void Object::operator delete | ( | void * | ptr | ) | [static, inherited] |
| void * Object::operator new | ( | size_t | size | ) | [static, inherited] |
| void Object::release | ( | ) | [inherited] |
Definition at line 66 of file object.cc.
References zmm::Object::_ref_count, atomic_dec(), and zmm::Object::mutex.
Referenced by zmm::ArrayBase::clear(), zmm::String::operator=(), DSOHash< zmm::Array< CacheObject > >::releaseData(), DSBHash< VT >::releaseData(), DSOHash< zmm::Array< CacheObject > >::remove(), zmm::ArrayBase::remove(), zmm::ArrayBase::removeUnordered(), zmm::ArrayBase::set(), zmm::ArrayBase::~ArrayBase(), DSOHash< zmm::Array< CacheObject > >::~DSOHash(), zmm::ObjectQueue< AutoscanDirectory >::~ObjectQueue(), zmm::ObjectStack< Element >::~ObjectStack(), and zmm::String::~String().
| void Object::retain | ( | ) | [inherited] |
Definition at line 58 of file object.cc.
References zmm::Object::_ref_count, atomic_inc(), and zmm::Object::mutex.
Referenced by zmm::ArrayBase::append(), zmm::ObjectQueue< AutoscanDirectory >::enqueue(), zmm::ArrayBase::insert(), zmm::String::operator=(), zmm::ObjectStack< Element >::push(), DSOHash< zmm::Array< CacheObject > >::put(), DSBHash< VT >::put(), zmm::ArrayBase::set(), and zmm::String::String().
| void ThreadExecutor::startThread | ( | ) | [protected, inherited] |
start the thread
Definition at line 53 of file thread_executor.cc.
References NULL, ThreadExecutor::staticThreadProc(), ThreadExecutor::thread, and ThreadExecutor::threadRunning.
Referenced by IOHandlerChainer::IOHandlerChainer().
| virtual void MPEGRemuxProcessor::threadProc | ( | ) | [protected, virtual] |
abstract thread method, which needs to be overridden
Implements ThreadExecutor.
| bool ThreadExecutor::threadShutdownCheck | ( | ) | [inline, protected, inherited] |
check if the thread should shutdown should be called by the threadProc in short intervals
Definition at line 73 of file thread_executor.h.
References ThreadExecutor::threadShutdown.
Referenced by IOHandlerChainer::threadProc().
mt_atomic_t zmm::Object::_ref_count [protected, inherited] |
Definition at line 54 of file object.h.
Referenced by zmm::Object::getRefCount(), zmm::Object::Object(), zmm::Object::release(), and zmm::Object::retain().
zmm::Ref<Cond> ThreadExecutor::cond [protected, inherited] |
Definition at line 62 of file thread_executor.h.
Referenced by ThreadExecutor::kill(), and ThreadExecutor::ThreadExecutor().
int MPEGRemuxProcessor::in_fd [private] |
Definition at line 57 of file mpegremux_processor.h.
unsigned char MPEGRemuxProcessor::keep_audio_id [private] |
Definition at line 59 of file mpegremux_processor.h.
zmm::Ref<Mutex> ThreadExecutor::mutex [protected, inherited] |
Reimplemented from zmm::Object.
Definition at line 63 of file thread_executor.h.
Referenced by ThreadExecutor::kill(), and ThreadExecutor::ThreadExecutor().
int MPEGRemuxProcessor::out_fd [private] |
Definition at line 58 of file mpegremux_processor.h.
int MPEGRemuxProcessor::status [private] |
Definition at line 56 of file mpegremux_processor.h.
Referenced by getStatus().
bool ThreadExecutor::threadRunning [protected, inherited] |
if the thread is currently running
Definition at line 60 of file thread_executor.h.
Referenced by ThreadExecutor::isAlive(), ThreadExecutor::kill(), and ThreadExecutor::startThread().
bool ThreadExecutor::threadShutdown [protected, inherited] |
Definition at line 58 of file thread_executor.h.
Referenced by ThreadExecutor::kill(), ThreadExecutor::ThreadExecutor(), and ThreadExecutor::threadShutdownCheck().
1.6.1