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 63 64 65 66 67 68 69 70 71 72 73 74
|
<html>
<head>
<title>Camstream: CamStream API documentation</title>
<link rel="stylesheet" href="../../tech.css" type="text/css">
</head>
<body>
<!-- Generated by Doxygen 1.2.6 -->
<center>
<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </center>
<hr><h1>debug.h</h1><a href="debug_h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <font class="comment">/* For debugging the various program modules. </font>
00002 <font class="comment"> </font>
00003 <font class="comment"> All variables start with TRACE_; use a level to determine how much is </font>
00004 <font class="comment"> logged; 0 is minimal (or no) logging, higher numbers should log more.</font>
00005 <font class="comment"></font>
00006 <font class="comment"> To enable tracing, #define ENABLE_TRACING in the file that you want to </font>
00007 <font class="comment"> trace, before you include "config.h" or "debug.h".</font>
00008 <font class="comment"> </font>
00009 <font class="comment"> Use the macro like this:</font>
00010 <font class="comment"> </font>
00011 <font class="comment"> Trace(CONFIGFILE, 3, "Opening log file");</font>
00012 <font class="comment"> </font>
00013 <font class="comment"> This message will only be printed if TRACE_CONFIGFILE is >= 3, i.e. very</font>
00014 <font class="comment"> verbose. A newline is automatically appended.</font>
00015 <font class="comment"></font>
00016 <font class="comment"> */</font>
00017
00018 <font class="preprocessor">#ifdef ENABLE_TRACING</font>
00019 <font class="preprocessor"></font><font class="preprocessor">#undef Trace</font>
00020 <font class="preprocessor"></font><font class="preprocessor">#define Trace(what, level, string...) \</font>
00021 <font class="preprocessor"> if (TRACE_##what >= level) { \</font>
00022 <font class="preprocessor"> fprintf(stderr, string); \</font>
00023 <font class="preprocessor"> fprintf(stderr, "\n"); \</font>
00024 <font class="preprocessor"> }</font>
00025 <font class="preprocessor"></font><font class="preprocessor">#else</font>
00026 <font class="preprocessor"></font><font class="preprocessor">#undef Trace</font>
<a name="l00027"></a><a class="code" href="debug_h.html#a0">00027</a> <font class="preprocessor"></font><font class="preprocessor">#define Trace(what, level, string...) </font><font class="comment">/* nop */</font>
00028 <font class="preprocessor">#endif</font>
00029 <font class="preprocessor"></font>
00030
<a name="l00031"></a><a class="code" href="debug_h.html#a1">00031</a> <font class="preprocessor">#define TRACE_CONFIGFILE 1</font>
00032 <font class="preprocessor"></font>
<a name="l00033"></a><a class="code" href="debug_h.html#a2">00033</a> <font class="preprocessor">#define TRACE_PANELREG 1</font>
<a name="l00034"></a><a class="code" href="debug_h.html#a3">00034</a> <font class="preprocessor"></font><font class="preprocessor">#define TRACE_PANELPOS 1</font>
<a name="l00035"></a><a class="code" href="debug_h.html#a4">00035</a> <font class="preprocessor"></font><font class="preprocessor">#define TRACE_PANELSIGNALS 1</font>
00036 <font class="preprocessor"></font>
00037 <font class="comment">// CamCanvas.cc</font>
<a name="l00038"></a><a class="code" href="debug_h.html#a5">00038</a> <font class="preprocessor">#define TRACE_CANVAS_OPEN 1</font>
00039 <font class="preprocessor"></font>
00040 <font class="comment">// VideoCollector.cc</font>
00041 <font class="comment">/* #define TRACE_VIDEOCOLLECTOR 1 */</font>
00042 <font class="preprocessor">#undef TRACE_VIDEOCOLLECTOR</font>
00043 <font class="preprocessor"></font>
00044 <font class="comment">// VideoDevice.cc</font>
00045 <font class="preprocessor">#undef TRACE_VIDEODEV_READ</font>
<a name="l00046"></a><a class="code" href="debug_h.html#a6">00046</a> <font class="preprocessor"></font><font class="preprocessor">#define TRACE_VIDEODEV_OPEN 1</font>
<a name="l00047"></a><a class="code" href="debug_h.html#a7">00047</a> <font class="preprocessor"></font><font class="preprocessor">#define TRACE_VIDEODEV_IOCTL 1</font>
00048 <font class="preprocessor"></font>
00049
00050 <font class="comment">/* 'Philips Control' dialog */</font>
<a name="l00051"></a><a class="code" href="debug_h.html#a8">00051</a> <font class="preprocessor">#define TRACE_PHCONTROL_DLG 2</font>
00052 <font class="preprocessor"></font>
00053 <font class="comment">/* FTP */</font>
<a name="l00054"></a><a class="code" href="debug_h.html#a9">00054</a> <font class="preprocessor">#define TRACE_FTP 2</font>
00055 <font class="preprocessor"></font>
00056 <font class="comment">/* VideoOptions */</font>
<a name="l00057"></a><a class="code" href="debug_h.html#a10">00057</a> <font class="preprocessor">#define TRACE_VIDEOOPTIONS 2</font>
</font></pre></div><hr><address><small>Generated at Sat May 18 02:56:55 2002 for Camstream by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.gif" alt="doxygen" align="middle" border=0
width=110 height=53></a>1.2.6 written by <a href="mailto:dimitri@stack.nl">Dimitri van Heesch</a>,
© 1997-2001</small></address>
</body>
</html>
|