mirror of
https://github.com/tuxbox-neutrino/libstb-hal.git
synced 2025-08-27 07:23:11 +02:00
libeplayer3/input: disable avformat logging
This commit is contained in:
@@ -20,6 +20,8 @@
|
|||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define ENABLE_AVLOG 0
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
@@ -262,6 +264,7 @@ bool Input::Play()
|
|||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if ENABLE_AVLOG
|
||||||
static std::string lastlog_message;
|
static std::string lastlog_message;
|
||||||
static unsigned int lastlog_repeats;
|
static unsigned int lastlog_repeats;
|
||||||
|
|
||||||
@@ -279,6 +282,7 @@ static void log_callback(void *ptr __attribute__ ((unused)), int lvl __attribute
|
|||||||
lastlog_repeats++;
|
lastlog_repeats++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
bool Input::ReadSubtitle(const char *filename, const char *format, int pid)
|
bool Input::ReadSubtitle(const char *filename, const char *format, int pid)
|
||||||
{
|
{
|
||||||
@@ -356,7 +360,9 @@ bool Input::ReadSubtitles(const char *filename) {
|
|||||||
bool Input::Init(const char *filename)
|
bool Input::Init(const char *filename)
|
||||||
{
|
{
|
||||||
abortPlayback = false;
|
abortPlayback = false;
|
||||||
|
#if ENABLE_AVLOG
|
||||||
av_log_set_callback(log_callback);
|
av_log_set_callback(log_callback);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (!filename) {
|
if (!filename) {
|
||||||
fprintf(stderr, "filename NULL\n");
|
fprintf(stderr, "filename NULL\n");
|
||||||
|
Reference in New Issue
Block a user