File: log.h

package info (click to toggle)
flvstreamer 2.1c1-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 364 kB
  • sloc: ansic: 7,815; makefile: 47
file content (62 lines) | stat: -rw-r--r-- 1,737 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/*  RTMP Dump
 *  Copyright (C) 2008-2009 Andrej Stepanchuk
 *  Copyright (C) 2009 Howard Chu
 *
 *  This Program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2, or (at your option)
 *  any later version.
 *
 *  This Program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with flvstreamer; see the file COPYING.  If not, write to
 *  the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
 *  http://www.gnu.org/copyleft/gpl.html
 *
 */

#ifndef __LOG_H__
#define __LOG_H__

#include <stdio.h>

#ifdef __cplusplus
extern "C" {
#endif
/* Enable this to get full debugging output */
/* #define _DEBUG */

#ifdef _DEBUG
#undef NODEBUG
#endif

typedef enum
{ LOGCRIT=0, LOGERROR, LOGWARNING, LOGINFO,
  LOGDEBUG, LOGDEBUG2, LOGALL
} AMF_LogLevel;

#define Log	AMF_Log
#define LogHex	AMF_LogHex
#define LogHexString	AMF_LogHexString
#define LogPrintf	AMF_LogPrintf
#define LogSetOutput	AMF_LogSetOutput
#define LogStatus	AMF_LogStatus
#define debuglevel	AMF_debuglevel

extern AMF_LogLevel debuglevel;

void LogSetOutput(FILE *file);
void LogPrintf(const char *format, ...);
void LogStatus(const char *format, ...);
void Log(int level, const char *format, ...);
void LogHex(int level, const char *data, unsigned long len);
void LogHexString(int level, const char *data, unsigned long len);

#ifdef __cplusplus
}
#endif
#endif