summaryrefslogtreecommitdiff
path: root/va/va_trace.h
diff options
context:
space:
mode:
authorAustin Yuan <shengquan.yuan@gmail.com>2011-09-21 23:29:45 -0400
committerAustin Yuan <shengquan.yuan@gmail.com>2011-09-22 00:58:01 -0400
commit549946cf2c5e0c5884d3137b1393967a6a891784 (patch)
treee503076a5cb20253672f75bc9f90effcaed25381 /va/va_trace.h
parent1092e4b54a476260e3c74d87ebb1a552e8fef71e (diff)
vatrace/vafool: refine it
remove va_fool_getframe.c which looks strange correct some coding style for file va.c simplify va_fool.c for both decode and encode refine the surface dump of va_trace.c Signed-off-by: Austin Yuan <shengquan.yuan@gmail.com>
Diffstat (limited to 'va/va_trace.h')
-rw-r--r--va/va_trace.h37
1 files changed, 35 insertions, 2 deletions
diff --git a/va/va_trace.h b/va/va_trace.h
index e8ae4f7..43b9fb8 100644
--- a/va/va_trace.h
+++ b/va/va_trace.h
@@ -25,6 +25,35 @@
#ifndef VA_TRACE_H
#define VA_TRACE_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+extern int trace_flag;
+
+#define VA_TRACE_FLAG_LOG 0x1
+#define VA_TRACE_FLAG_BUFDATA 0x2
+#define VA_TRACE_FLAG_CODEDBUF 0x4
+#define VA_TRACE_FLAG_SURFACE_DECODE 0x8
+#define VA_TRACE_FLAG_SURFACE_ENCODE 0x10
+#define VA_TRACE_FLAG_SURFACE_JPEG 0x20
+#define VA_TRACE_FLAG_SURFACE (VA_TRACE_FLAG_SURFACE_DECODE | \
+ VA_TRACE_FLAG_SURFACE_ENCODE | \
+ VA_TRACE_FLAG_SURFACE_JPEG)
+
+#define VA_TRACE_FUNC(trace_func,...) \
+ if (trace_flag) { \
+ trace_func(__VA_ARGS__); \
+ }
+#define VA_TRACE_LOG(trace_func,...) \
+ if (trace_flag & VA_TRACE_FLAG_LOG) { \
+ trace_func(__VA_ARGS__); \
+ }
+#define VA_TRACE_SURFACE(trace_func,...) \
+ if (trace_flag & (VA_TRACE_FLAG_SURFACE | VA_TRACE_FLAG_CODEDBUF)) { \
+ trace_func(__VA_ARGS__); \
+ }
+
void va_TraceInit(VADisplay dpy);
void va_TraceEnd(VADisplay dpy);
@@ -92,7 +121,8 @@ void va_TraceRenderPicture(
void va_TraceEndPicture(
VADisplay dpy,
- VAContextID context
+ VAContextID context,
+ int endpic_done
);
void va_TraceSyncSurface(
@@ -155,6 +185,9 @@ void va_TracePutSurface (
unsigned int flags /* de-interlacing flags */
);
-
+#ifdef __cplusplus
+}
+#endif
+
#endif /* VA_TRACE_H */