mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-02 10:21:04 +02:00
Merge branch 'ni/tuxbox' into ni/mp/tuxbox
Conflicts:
configure.ac
lib/Makefile.am
src/Makefile.am
Origin commit data
------------------
Commit: 3ed2ebe75b
Author: vanhofen <vanhofen@gmx.de>
Date: 2016-10-25 (Tue, 25 Oct 2016)
This commit is contained in:
@@ -64,6 +64,37 @@
|
||||
#include <timerdclient/timerdclient.h>
|
||||
#include <cs_api.h>
|
||||
|
||||
extern "C" {
|
||||
#include <libavformat/avformat.h>
|
||||
}
|
||||
|
||||
class CStreamRec : public CRecordInstance, OpenThreads::Thread
|
||||
{
|
||||
private:
|
||||
AVFormatContext *ifcx;
|
||||
AVFormatContext *ofcx;
|
||||
AVBitStreamFilterContext *bsfc;
|
||||
bool stopped;
|
||||
bool interrupt;
|
||||
time_t time_started;
|
||||
int stream_index;
|
||||
|
||||
void GetPids(CZapitChannel * channel);
|
||||
void FillMovieInfo(CZapitChannel * channel, APIDList & apid_list);
|
||||
bool Start();
|
||||
|
||||
void Close();
|
||||
bool Open(CZapitChannel * channel);
|
||||
void run();
|
||||
void WriteHeader(uint32_t duration);
|
||||
public:
|
||||
CStreamRec(const CTimerd::RecordingInfo * const eventinfo, std::string &dir, bool timeshift = false, bool stream_vtxt_pid = false, bool stream_pmt_pid = false, bool stream_subtitle_pids = false);
|
||||
~CStreamRec();
|
||||
record_error_msg_t Record();
|
||||
bool Stop(bool remove_event = true);
|
||||
static int Interrupt(void * data);
|
||||
};
|
||||
|
||||
/* TODO:
|
||||
* nextRecording / pending recordings - needs testing
|
||||
* check/fix askUserOnTimerConflict gui/timerlist.cpp -> getOverlappingTimers lib/timerdclient/timerdclient.cpp
|
||||
@@ -2249,7 +2280,7 @@ void CStreamRec::run()
|
||||
continue;
|
||||
|
||||
AVCodecContext *codec = ifcx->streams[pkt.stream_index]->codec;
|
||||
if (bsfc && codec->codec_id == CODEC_ID_H264) {
|
||||
if (bsfc && codec->codec_id == AV_CODEC_ID_H264) {
|
||||
AVPacket newpkt = pkt;
|
||||
|
||||
if (av_bitstream_filter_filter(bsfc, codec, NULL, &newpkt.data, &newpkt.size, pkt.data, pkt.size, pkt.flags & AV_PKT_FLAG_KEY) >= 0) {
|
||||
|
Reference in New Issue
Block a user