diff --git a/libtriple/audio_td.cpp b/libtriple/audio_td.cpp index 8350118..555db92 100644 --- a/libtriple/audio_td.cpp +++ b/libtriple/audio_td.cpp @@ -8,6 +8,7 @@ #include #define AUDIO_DEVICE "/dev/" DEVICE_NAME_AUDIO #include "audio_td.h" +#include "lt_debug.h" cAudio * audioDecoder = NULL; @@ -124,7 +125,7 @@ bool cAudio::Pause(bool /*Pcm*/) void cAudio::SetSyncMode(AVSYNC_TYPE /*Mode*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); }; void cAudio::SetStreamType(AUDIO_FORMAT type) @@ -147,25 +148,25 @@ void cAudio::SetStreamType(AUDIO_FORMAT type) int cAudio::setChannel(int /*channel*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); return 0; }; int cAudio::PrepareClipPlay(int /*uNoOfChannels*/, int /*uSampleRate*/, int /*uBitsPerSample*/, int /*bLittleEndian*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); return 0; }; int cAudio::WriteClip(unsigned char * /*buffer*/, int /*size*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); return 0; }; int cAudio::StopClip() { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); return 0; }; @@ -213,22 +214,22 @@ void cAudio::getAudioInfo(int &type, int &layer, int &freq, int &bitrate, int &m void cAudio::SetSRS(int /*iq_enable*/, int /*nmgr_enable*/, int /*iq_mode*/, int /*iq_level*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); }; void cAudio::SetSpdifDD(bool /*enable*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); }; void cAudio::ScheduleMute(bool /*On*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); }; void cAudio::EnableAnalogOut(bool /*enable*/) { - fprintf(stderr, "cAudio::%s\n", __FUNCTION__); + lt_debug("cAudio::%s\n", __FUNCTION__); }; void cAudio::setBypassMode(bool disable) diff --git a/libtriple/dmx_td.cpp b/libtriple/dmx_td.cpp index e564001..dac776a 100644 --- a/libtriple/dmx_td.cpp +++ b/libtriple/dmx_td.cpp @@ -48,7 +48,7 @@ cDemux::cDemux(int n) cDemux::~cDemux() { - fprintf(stderr, "cDemux::%s #%d fd: %d\n", __FUNCTION__, num, fd); + lt_debug("cDemux::%s #%d fd: %d\n", __FUNCTION__, num, fd); Close(); } @@ -102,7 +102,7 @@ void cDemux::Close(void) for (std::vector::const_iterator i = pesfds.begin(); i != pesfds.end(); ++i) { - fprintf(stderr, "iterator: stopping and closing demux fd %d\n", *i); + lt_debug("cDemux::Close: stopping and closing demux fd %d\n", *i); if (ioctl(*i, DEMUX_STOP) < 0) perror("DEMUX_STOP"); if (close(*i) < 0) @@ -124,7 +124,7 @@ bool cDemux::Start(void) for (std::vector::const_iterator i = pesfds.begin(); i != pesfds.end(); ++i) { - fprintf(stderr, "iterator: starting demux fd %d\n", *i); + lt_debug("cDemux::Start: starting demux fd %d\n", *i); if (ioctl(*i, DEMUX_START) < 0) perror("DEMUX_START"); } @@ -141,7 +141,7 @@ bool cDemux::Stop(void) } for (std::vector::const_iterator i = pesfds.begin(); i != pesfds.end(); ++i) { - fprintf(stderr, "iterator: stopping demux fd %d\n", *i); + lt_debug("cDemux::Stop: stopping demux fd %d\n", *i); if (ioctl(*i, DEMUX_STOP) < 0) perror("DEMUX_STOP"); } @@ -325,7 +325,7 @@ bool cDemux::pesFilter(const unsigned short pid) if ((pid >= 0x0002 && pid <= 0x000f) || pid >= 0x1fff) return false; -fprintf(stderr, "cDemux::%s #%d pid: 0x%04hx fd: %d type: %s\n", __FUNCTION__, num, pid, fd, DMX_T[dmx_type]); + lt_debug("cDemux::%s #%d pid: 0x%04hx fd: %d type: %s\n", __FUNCTION__, num, pid, fd, DMX_T[dmx_type]); if (dmx_type == DMX_TP_CHANNEL) { @@ -360,18 +360,18 @@ fprintf(stderr, "cDemux::%s #%d pid: 0x%04hx fd: %d type: %s\n", __FUNCTION__, n void cDemux::SetSyncMode(AVSYNC_TYPE /*mode*/) { - fprintf(stderr, "cDemux::%s #%d\n", __FUNCTION__, num); + lt_debug("cDemux::%s #%d\n", __FUNCTION__, num); } void *cDemux::getBuffer() { - fprintf(stderr, "cDemux::%s #%d\n", __FUNCTION__, num); + lt_debug("cDemux::%s #%d\n", __FUNCTION__, num); return NULL; } void *cDemux::getChannel() { - fprintf(stderr, "cDemux::%s #%d\n", __FUNCTION__, num); + lt_debug("cDemux::%s #%d\n", __FUNCTION__, num); return NULL; } @@ -393,7 +393,7 @@ void cDemux::addPid(unsigned short Pid) fprintf(stderr, "cDemux::%s #%d Pid = %hx open failed (%m)\n", __FUNCTION__, num, Pid); return; } - fprintf(stderr, "cDemux::%s #%d Pid = %hx pfd = %d\n", __FUNCTION__, num, Pid, pfd); + lt_debug("cDemux::%s #%d Pid = %hx pfd = %d\n", __FUNCTION__, num, Pid, pfd); p.pid = Pid; p.pesType = DMX_PES_OTHER; diff --git a/libtriple/video_td.cpp b/libtriple/video_td.cpp index 812e184..b1a8cad 100644 --- a/libtriple/video_td.cpp +++ b/libtriple/video_td.cpp @@ -39,6 +39,7 @@ #include "video_td.h" #include #define VIDEO_DEVICE "/dev/" DEVICE_NAME_VIDEO +#include "lt_debug.h" cVideo * videoDecoder = NULL; int system_rev = 0; @@ -458,7 +459,7 @@ void cVideo::Standby(unsigned int bOn) int cVideo::getBlank(void) { - fprintf(stderr, "cVideo::getBlank\n"); + lt_debug("cVideo::getBlank\n"); return 0; } @@ -586,7 +587,7 @@ void cVideo::getPictureInfo(int &width, int &height, int &rate) void cVideo::SetSyncMode(AVSYNC_TYPE /*Mode*/) { - fprintf(stderr, "cVideo::%s\n", __FUNCTION__); + lt_debug("cVideo::%s\n", __FUNCTION__); }; int cVideo::SetStreamType(VIDEO_FORMAT type)