Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2010 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | #ifndef ANDROID_HWUI_DEBUG_H |
| 18 | #define ANDROID_HWUI_DEBUG_H |
| 19 | |
| 20 | // Turn on to check for OpenGL errors on each frame |
| 21 | #define DEBUG_OPENGL 1 |
| 22 | |
Romain Guy | a60c388 | 2011-08-01 15:28:16 -0700 | [diff] [blame] | 23 | // Turn on to display informations about the GPU |
| 24 | #define DEBUG_EXTENSIONS 0 |
| 25 | |
Romain Guy | c9855a5 | 2011-01-21 21:14:15 -0800 | [diff] [blame] | 26 | // Turn on to enable initialization information |
| 27 | #define DEBUG_INIT 0 |
| 28 | |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 29 | // Turn on to enable memory usage summary on each frame |
| 30 | #define DEBUG_MEMORY_USAGE 0 |
| 31 | |
Romain Guy | bdf7609 | 2011-07-18 15:00:43 -0700 | [diff] [blame] | 32 | // Turn on to enable debugging of cache flushes |
Romain Guy | 9c10ab0 | 2012-02-22 14:34:58 -0800 | [diff] [blame] | 33 | #define DEBUG_CACHE_FLUSH 0 |
Romain Guy | bdf7609 | 2011-07-18 15:00:43 -0700 | [diff] [blame] | 34 | |
Romain Guy | aaceeb0 | 2011-03-23 19:56:13 -0700 | [diff] [blame] | 35 | // Turn on to enable layers debugging when rendered as regions |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 36 | #define DEBUG_LAYERS_AS_REGIONS 0 |
| 37 | |
Romain Guy | 735738c | 2012-12-03 12:34:51 -0800 | [diff] [blame] | 38 | // Turn on to enable debugging when the clip is not a rect |
| 39 | #define DEBUG_CLIP_REGIONS 0 |
| 40 | |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 41 | // Turn on to display debug info about vertex/fragment shaders |
| 42 | #define DEBUG_PROGRAMS 0 |
| 43 | |
| 44 | // Turn on to display info about layers |
| 45 | #define DEBUG_LAYERS 0 |
| 46 | |
Romain Guy | 8d4aeb7 | 2013-02-12 16:08:55 -0800 | [diff] [blame] | 47 | // Turn on to display info about render buffers |
| 48 | #define DEBUG_RENDER_BUFFERS 0 |
| 49 | |
Romain Guy | 3bbacf2 | 2013-02-06 16:51:04 -0800 | [diff] [blame] | 50 | // Turn on to make stencil operations easier to debug |
| 51 | #define DEBUG_STENCIL 0 |
| 52 | |
Romain Guy | aaceeb0 | 2011-03-23 19:56:13 -0700 | [diff] [blame] | 53 | // Turn on to display debug info about 9patch objects |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 54 | #define DEBUG_PATCHES 0 |
Romain Guy | f504a2f | 2011-05-26 16:40:55 -0700 | [diff] [blame] | 55 | // Turn on to "explode" 9patch objects |
| 56 | #define DEBUG_EXPLODE_PATCHES 0 |
Romain Guy | a5ef39a | 2010-12-03 16:48:20 -0800 | [diff] [blame] | 57 | // Turn on to display vertex and tex coords data about 9patch objects |
| 58 | // This flag requires DEBUG_PATCHES to be turned on |
| 59 | #define DEBUG_PATCHES_VERTICES 0 |
Romain Guy | fb13abd | 2011-01-16 15:16:38 -0800 | [diff] [blame] | 60 | // Turn on to display vertex and tex coords data used by empty quads |
| 61 | // in 9patch objects |
| 62 | // This flag requires DEBUG_PATCHES to be turned on |
| 63 | #define DEBUG_PATCHES_EMPTY_VERTICES 0 |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 64 | |
Romain Guy | 01d58e4 | 2011-01-19 21:54:02 -0800 | [diff] [blame] | 65 | // Turn on to display debug info about shapes |
| 66 | #define DEBUG_SHAPES 0 |
| 67 | |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 68 | // Turn on to display debug info about textures |
| 69 | #define DEBUG_TEXTURES 0 |
| 70 | |
Romain Guy | 1fc883b | 2011-01-12 14:30:59 -0800 | [diff] [blame] | 71 | // Turn on to display debug info about the layer renderer |
| 72 | #define DEBUG_LAYER_RENDERER 0 |
| 73 | |
Romain Guy | b629490 | 2012-02-02 15:13:18 -0800 | [diff] [blame] | 74 | // Turn on to enable additional debugging in the font renderers |
| 75 | #define DEBUG_FONT_RENDERER 0 |
| 76 | |
Chris Craik | c3566d0 | 2013-02-04 16:16:33 -0800 | [diff] [blame^] | 77 | // Turn on to log draw operation batching and deferral information |
| 78 | #define DEBUG_DEFER 0 |
| 79 | |
Romain Guy | ffac7fc | 2011-01-13 17:21:49 -0800 | [diff] [blame] | 80 | // Turn on to dump display list state |
| 81 | #define DEBUG_DISPLAY_LIST 0 |
| 82 | |
Romain Guy | 8a4ac61 | 2012-07-17 17:32:48 -0700 | [diff] [blame] | 83 | // Turn on to insert an event marker for each display list op |
| 84 | #define DEBUG_DISPLAY_LIST_OPS_AS_EVENTS 0 |
| 85 | |
Romain Guy | c9855a5 | 2011-01-21 21:14:15 -0800 | [diff] [blame] | 86 | #if DEBUG_INIT |
Steve Block | 5baa3a6 | 2011-12-20 16:23:08 +0000 | [diff] [blame] | 87 | #define INIT_LOGD(...) ALOGD(__VA_ARGS__) |
Romain Guy | c9855a5 | 2011-01-21 21:14:15 -0800 | [diff] [blame] | 88 | #else |
| 89 | #define INIT_LOGD(...) |
| 90 | #endif |
| 91 | |
Romain Guy | c15008e | 2010-11-10 11:59:15 -0800 | [diff] [blame] | 92 | #endif // ANDROID_HWUI_DEBUG_H |