#include <dvbrecorder.h>

Definition at line 38 of file dvbrecorder.h.
Public Member Functions | |
| DVBRecorder (TVRec *rec, DVBChannel *dvbchannel) | |
| ~DVBRecorder () | |
| void | SetOption (const QString &name, int value) |
| handles the "wait_for_seqstart" and "pkt_buf_size" options. | |
| void | SetOptionsFromProfile (RecordingProfile *profile, const QString &videodev, const QString &audiodev, const QString &vbidev) |
| Sets basic recorder options. | |
| void | StartRecording (void) |
| StartRecording() starts the recording process, and does not exit until the recording is complete. | |
| void | ResetForNewFile (void) |
| void | StopRecording (void) |
| StopRecording() signals to the StartRecording() function that it should stop recording and exit cleanly. | |
| bool | Open (void) |
| Open devices needed by recorder. | |
| bool | IsOpen (void) const |
| void | Close (void) |
| void | HandlePAT (const ProgramAssociationTable *) |
| void | HandleCAT (const ConditionalAccessTable *) |
| void | HandlePMT (uint pid, const ProgramMapTable *) |
| void | HandleEncryptionStatus (uint, bool) |
| void | HandleSingleProgramPAT (ProgramAssociationTable *pat) |
| void | HandleSingleProgramPMT (ProgramMapTable *) |
| void | HandleSTT (const SystemTimeTable *) |
| void | HandleVCT (uint, const VirtualChannelTable *) |
| void | HandleMGT (const MasterGuideTable *) |
| void | HandleTDT (const TimeDateTable *) |
| void | HandleNIT (const NetworkInformationTable *) |
| void | HandleSDT (uint, const ServiceDescriptionTable *) |
| bool | ProcessTSPacket (const TSPacket &tspacket) |
| bool | ProcessVideoTSPacket (const TSPacket &tspacket) |
| bool | ProcessAudioTSPacket (const TSPacket &tspacket) |
| bool | ProcessAVTSPacket (const TSPacket &tspacket) |
| Common code for processing either audio or video packets. | |
| void | SetStreamData (MPEGStreamData *) |
| MPEGStreamData * | GetStreamData (void) |
| void | BufferedWrite (const TSPacket &tspacket) |
Private Member Functions | |
| void | TeardownAll (void) |
| bool | CheckCC (uint pid, uint cc) |
| void | ReaderPaused (int fd) |
| bool | PauseAndWait (int timeout=100) |
| If request_pause is true Paused and blocks up to timeout milliseconds. | |
Private Attributes | |
| int | _card_number_option |
| DVBChannel * | dvbchannel |
| DVBStreamHandler * | _stream_handler |
| MPEGStreamData * | _stream_data |
| QMutex | _pid_lock |
| ProgramAssociationTable * | _input_pat |
| PAT on input side. | |
| ProgramMapTable * | _input_pmt |
| PMT on input side. | |
| bool | _has_no_av |
| unsigned char | _stream_id [0x1fff] |
| unsigned char | _pid_status [0x1fff] |
| unsigned char | _continuity_counter [0x1fff] |
| uint | _continuity_error_count |
| uint | _stream_overflow_count |
| uint | _bad_packet_count |
Static Private Attributes | |
| static const int | TSPACKETS_BETWEEN_PSIP_SYNC = 20000 |
| static const int | POLL_INTERVAL = 50 |
| static const int | POLL_WARNING_TIMEOUT = 500 |
| static const unsigned char | kPayloadStartSeen = 0x2 |
| DVBRecorder::DVBRecorder | ( | TVRec * | rec, | |
| DVBChannel * | dvbchannel | |||
| ) |
Definition at line 95 of file dvbrecorder.cpp.
| DVBRecorder::~DVBRecorder | ( | ) |
Definition at line 116 of file dvbrecorder.cpp.
| void DVBRecorder::SetOption | ( | const QString & | name, | |
| int | value | |||
| ) | [virtual] |
handles the "wait_for_seqstart" and "pkt_buf_size" options.
Reimplemented from DTVRecorder.
Definition at line 148 of file dvbrecorder.cpp.
Referenced by SetOptionsFromProfile().
| void DVBRecorder::SetOptionsFromProfile | ( | RecordingProfile * | profile, | |
| const QString & | videodev, | |||
| const QString & | audiodev, | |||
| const QString & | vbidev | |||
| ) | [virtual] |
Sets basic recorder options.
SetOptionsFromProfile is used to tell the recorder about the recording profile as well as the devices to use.
Implements RecorderBase.
Definition at line 159 of file dvbrecorder.cpp.
| void DVBRecorder::StartRecording | ( | void | ) | [virtual] |
StartRecording() starts the recording process, and does not exit until the recording is complete.
Implements RecorderBase.
Definition at line 374 of file dvbrecorder.cpp.
| void DVBRecorder::ResetForNewFile | ( | void | ) | [virtual] |
| void DVBRecorder::StopRecording | ( | void | ) | [virtual] |
StopRecording() signals to the StartRecording() function that it should stop recording and exit cleanly.
This function should block until StartRecording() has finished up.
Reimplemented from DTVRecorder.
Definition at line 447 of file dvbrecorder.cpp.
Referenced by TeardownAll().
| bool DVBRecorder::Open | ( | void | ) | [virtual] |
Open devices needed by recorder.
This is usually called by StartRecording().
Implements RecorderBase.
Definition at line 313 of file dvbrecorder.cpp.
Referenced by StartRecording().
| bool DVBRecorder::IsOpen | ( | void | ) | const [inline] |
| void DVBRecorder::Close | ( | void | ) |
| void DVBRecorder::HandlePAT | ( | const ProgramAssociationTable * | _pat | ) | [virtual] |
| void DVBRecorder::HandleCAT | ( | const ConditionalAccessTable * | ) | [inline, virtual] |
| void DVBRecorder::HandlePMT | ( | uint | pid, | |
| const ProgramMapTable * | _pmt | |||
| ) | [virtual] |
| void DVBRecorder::HandleSingleProgramPAT | ( | ProgramAssociationTable * | pat | ) | [virtual] |
Implements MPEGSingleProgramStreamListener.
Definition at line 168 of file dvbrecorder.cpp.
Referenced by StartRecording().
| void DVBRecorder::HandleSingleProgramPMT | ( | ProgramMapTable * | pmt | ) | [virtual] |
Implements MPEGSingleProgramStreamListener.
Definition at line 202 of file dvbrecorder.cpp.
Referenced by StartRecording().
| void DVBRecorder::HandleSTT | ( | const SystemTimeTable * | ) | [virtual] |
| void DVBRecorder::HandleVCT | ( | uint | , | |
| const VirtualChannelTable * | ||||
| ) | [inline, virtual] |
| void DVBRecorder::HandleMGT | ( | const MasterGuideTable * | ) | [inline, virtual] |
| void DVBRecorder::HandleTDT | ( | const TimeDateTable * | ) | [virtual] |
| void DVBRecorder::HandleNIT | ( | const NetworkInformationTable * | ) | [inline, virtual] |
| void DVBRecorder::HandleSDT | ( | uint | , | |
| const ServiceDescriptionTable * | ||||
| ) | [inline, virtual] |
Common code for processing either audio or video packets.
Definition at line 516 of file dvbrecorder.cpp.
Referenced by ProcessAudioTSPacket(), and ProcessVideoTSPacket().
| void DVBRecorder::SetStreamData | ( | MPEGStreamData * | data | ) | [virtual] |
| MPEGStreamData* DVBRecorder::GetStreamData | ( | void | ) | [inline, virtual] |
Reimplemented from DTVRecorder.
Definition at line 97 of file dvbrecorder.h.
Referenced by HandleSTT(), and HandleTDT().
| void DVBRecorder::BufferedWrite | ( | const TSPacket & | tspacket | ) |
Reimplemented from DTVRecorder.
Definition at line 580 of file dvbrecorder.cpp.
Referenced by ProcessAVTSPacket(), and ProcessTSPacket().
| void DVBRecorder::TeardownAll | ( | void | ) | [private] |
Definition at line 143 of file dvbrecorder.h.
Referenced by ProcessAVTSPacket(), and ProcessTSPacket().
| void DVBRecorder::ReaderPaused | ( | int | fd | ) | [private, virtual] |
| bool DVBRecorder::PauseAndWait | ( | int | timeout = 100 |
) | [private, virtual] |
If request_pause is true Paused and blocks up to timeout milliseconds.
| timeout | number of milliseconds to wait defaults to 100. |
Reimplemented from RecorderBase.
Definition at line 458 of file dvbrecorder.cpp.
Referenced by StartRecording().
int DVBRecorder::_card_number_option [private] |
DVBChannel* DVBRecorder::dvbchannel [private] |
Definition at line 114 of file dvbrecorder.h.
Referenced by HandlePMT(), HandleSTT(), HandleTDT(), and StartRecording().
DVBStreamHandler* DVBRecorder::_stream_handler [private] |
Definition at line 115 of file dvbrecorder.h.
Referenced by Close(), Open(), PauseAndWait(), and StartRecording().
MPEGStreamData* DVBRecorder::_stream_data [private] |
Definition at line 118 of file dvbrecorder.h.
Referenced by GetStreamData(), HandlePAT(), HandlePMT(), PauseAndWait(), SetStreamData(), and StartRecording().
QMutex DVBRecorder::_pid_lock [mutable, private] |
ProgramAssociationTable* DVBRecorder::_input_pat [private] |
PAT on input side.
Definition at line 120 of file dvbrecorder.h.
Referenced by HandlePAT(), and TeardownAll().
ProgramMapTable* DVBRecorder::_input_pmt [private] |
PMT on input side.
Definition at line 121 of file dvbrecorder.h.
Referenced by HandlePMT(), ProcessTSPacket(), StartRecording(), and TeardownAll().
bool DVBRecorder::_has_no_av [private] |
unsigned char DVBRecorder::_stream_id[0x1fff] [private] |
Definition at line 125 of file dvbrecorder.h.
Referenced by HandleSingleProgramPMT(), Open(), ProcessVideoTSPacket(), and ResetForNewFile().
unsigned char DVBRecorder::_pid_status[0x1fff] [private] |
Definition at line 126 of file dvbrecorder.h.
Referenced by Open(), ProcessAVTSPacket(), and ResetForNewFile().
unsigned char DVBRecorder::_continuity_counter[0x1fff] [private] |
Definition at line 127 of file dvbrecorder.h.
Referenced by CheckCC(), Open(), and ResetForNewFile().
uint DVBRecorder::_continuity_error_count [mutable, private] |
Definition at line 130 of file dvbrecorder.h.
Referenced by ProcessAVTSPacket(), ProcessTSPacket(), and StartRecording().
uint DVBRecorder::_stream_overflow_count [mutable, private] |
uint DVBRecorder::_bad_packet_count [mutable, private] |
Definition at line 132 of file dvbrecorder.h.
const int DVBRecorder::TSPACKETS_BETWEEN_PSIP_SYNC = 20000 [static, private] |
Definition at line 135 of file dvbrecorder.h.
const int DVBRecorder::POLL_INTERVAL = 50 [static, private] |
Definition at line 136 of file dvbrecorder.h.
const int DVBRecorder::POLL_WARNING_TIMEOUT = 500 [static, private] |
Definition at line 137 of file dvbrecorder.h.
const unsigned char DVBRecorder::kPayloadStartSeen = 0x2 [static, private] |
1.5.5