gfx/skia/trunk/src/utils/SkDebugTrace.h

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/gfx/skia/trunk/src/utils/SkDebugTrace.h	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,24 @@
     1.4 +
     1.5 +/*
     1.6 + * Copyright 2011 Google Inc.
     1.7 + *
     1.8 + * Use of this source code is governed by a BSD-style license that can be
     1.9 + * found in the LICENSE file.
    1.10 + */
    1.11 +
    1.12 +#ifndef SkUserTrace_DEFINED
    1.13 +#define SkUserTrace_DEFINED
    1.14 +
    1.15 +/* Sample implementation of SkUserTrace that routes all of the
    1.16 +   trace macros to debug output stream.
    1.17 +   To use this, redefine SK_USER_TRACE_INCLUDE_FILE in
    1.18 +   include/config/SkUserConfig.h to point to this file
    1.19 +*/
    1.20 +#define SK_TRACE_EVENT0(event) \
    1.21 +  SkDebugf("Trace: %s\n", event)
    1.22 +#define SK_TRACE_EVENT1(event, name1, value1) \
    1.23 +  SkDebugf("Trace: %s (%s=%s)\n", event, name1, value1)
    1.24 +#define SK_TRACE_EVENT2(event, name1, value1, name2, value2) \
    1.25 +  SkDebugf("Trace: %s (%s=%s, %s=%s)\n", event, name1, value1, name2, value2)
    1.26 +
    1.27 +#endif

mercurial