spark: let cRecord use the demux passed as parameter

Origin commit data
------------------
Branch: master
Commit: f0cee92240
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2012-09-22 (Sat, 22 Sep 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Stefan Seyfried
2012-09-22 11:09:30 +02:00
parent 7ccb9441b3
commit e75bd2bcd2
2 changed files with 5 additions and 3 deletions

View File

@@ -22,13 +22,14 @@ void *execute_record_thread(void *c)
return NULL;
}
cRecord::cRecord(int /*num*/)
cRecord::cRecord(int num)
{
lt_info("%s\n", __func__);
lt_info("%s %d\n", __func__, num);
dmx = NULL;
record_thread_running = false;
file_fd = -1;
exit_flag = RECORD_STOPPED;
dmx_num = num;
}
cRecord::~cRecord()
@@ -59,7 +60,7 @@ bool cRecord::Start(int fd, unsigned short vpid, unsigned short * apids, int num
int i;
if (!dmx)
dmx = new cDemux(1);
dmx = new cDemux(dmx_num);
dmx->Open(DMX_TP_CHANNEL, NULL, 512*1024);
dmx->pesFilter(vpid);

View File

@@ -17,6 +17,7 @@ class cRecord
{
private:
int file_fd;
int dmx_num;
cDemux *dmx;
pthread_t record_thread;
bool record_thread_running;