[3.0] Clipping API feature in Actor
[platform/core/uifw/dali-core.git] / dali / internal / render / common / render-debug.cpp
index d5f1165..e5e1d23 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -26,7 +26,9 @@
 #include <dali/internal/render/common/render-item.h>
 #include <dali/internal/render/common/render-list.h>
 #include <dali/internal/render/common/render-instruction.h>
+#include <dali/internal/update/nodes/node.h>
 
+using Dali::Internal::SceneGraph::Node;
 using Dali::Internal::SceneGraph::RenderList;
 
 namespace Dali
@@ -38,6 +40,10 @@ namespace Internal
 namespace Render
 {
 
+// These functions should only be defined if they are being used by the #define in the header.
+// Otherwise they will contribute negatively to code coverage.
+#ifdef DALI_PRINT_RENDER_INFO
+
 void PrintFrameStart( BufferIndex bufferIndex )
 {
   DALI_LOG_RENDER_INFO( "RENDER START - bufferIndex: %d\n", bufferIndex );
@@ -71,35 +77,9 @@ void PrintRenderInstruction( const SceneGraph::RenderInstruction& instruction, B
 
 void PrintRenderList( const RenderList& list )
 {
-  unsigned int flags = list.GetFlags();
-
   std::stringstream debugStream;
   debugStream << "Rendering items";
 
-  if( flags )
-  {
-    debugStream << " with:";
-
-    if( flags & RenderList::STENCIL_BUFFER_ENABLED )
-    {
-      debugStream << " STENCIL_TEST";
-    }
-
-    if( flags & RenderList::STENCIL_WRITE )
-    {
-      debugStream << " STENCIL_WRITE";
-    }
-
-    if( flags & RenderList::STENCIL_CLEAR )
-    {
-      debugStream << " STENCIL_CLEAR";
-    }
-  }
-  else
-  {
-    debugStream << " without any STENCIL settings";
-  }
-
   if( list.IsClipping() )
   {
     debugStream << ", ClippingBox: " << list.GetClippingBox().x << "," << list.GetClippingBox().y << " " << list.GetClippingBox().width << "x" << list.GetClippingBox().height;
@@ -126,6 +106,8 @@ void PrintRendererCount( unsigned int frameCount, unsigned int rendererCount )
   }
 }
 
+#endif
+
 } // Render
 
 } // Internal