[Tizen] Implement partial update
[platform/core/uifw/dali-core.git] / automated-tests / src / dali / dali-test-suite-utils / test-render-surface.cpp
1 /*
2  * Copyright (c) 2019 Samsung Electronics Co., Ltd.
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
18 #include "test-render-surface.h"
19
20 namespace Dali
21 {
22
23 TestRenderSurface::TestRenderSurface( Dali::PositionSize positionSize )
24 : mPositionSize( positionSize ),
25   mBackgroundColor()
26 {
27 }
28
29 TestRenderSurface::~TestRenderSurface()
30 {
31 }
32
33 Dali::PositionSize TestRenderSurface::GetPositionSize() const
34 {
35   return mPositionSize;
36 };
37
38 void TestRenderSurface::GetDpi( unsigned int& dpiHorizontal, unsigned int& dpiVertical )
39 {
40   dpiHorizontal = dpiVertical = 96;
41 };
42
43 int TestRenderSurface::GetOrientation() const
44 {
45   return 0;
46 };
47
48 void TestRenderSurface::InitializeGraphics()
49 {
50 }
51
52 void TestRenderSurface::CreateSurface()
53 {
54 }
55
56 void TestRenderSurface::DestroySurface()
57 {
58 }
59
60 bool TestRenderSurface::ReplaceGraphicsSurface()
61 {
62   return false;
63 }
64
65 void TestRenderSurface::MoveResize( Dali::PositionSize positionSize )
66 {
67   mPositionSize = positionSize;
68 }
69
70 void TestRenderSurface::StartRender()
71 {
72 }
73
74 bool TestRenderSurface::PreRender( bool resizingSurface )
75 {
76   return true;
77 }
78
79 void TestRenderSurface::PostRender( bool renderToFbo, bool replacingSurface, bool resizingSurface )
80 {
81 }
82
83 void TestRenderSurface::StopRender()
84 {
85 }
86
87 void TestRenderSurface::ReleaseLock()
88 {
89 }
90
91 Dali::Integration::RenderSurface::Type TestRenderSurface::GetSurfaceType()
92 {
93   return WINDOW_RENDER_SURFACE;
94 }
95
96 void TestRenderSurface::MakeContextCurrent()
97 {
98 }
99
100 Integration::DepthBufferAvailable TestRenderSurface::GetDepthBufferRequired()
101 {
102   return Integration::DepthBufferAvailable::TRUE;
103 }
104
105 Integration::StencilBufferAvailable TestRenderSurface::GetStencilBufferRequired()
106 {
107   return Integration::StencilBufferAvailable::TRUE;
108 }
109
110 void TestRenderSurface::SetBackgroundColor( Vector4 color )
111 {
112   mBackgroundColor = color;
113 }
114
115 Vector4 TestRenderSurface::GetBackgroundColor()
116 {
117   return mBackgroundColor;
118 }
119
120 Rect<int32_t> TestRenderSurface::SetDamagedRect( Rect<int32_t> damagedRectArray )
121 {
122   return damagedRectArray;
123 }
124
125 int32_t TestRenderSurface::GetBufferAge()
126 {
127   return 0;
128 }
129
130
131 } // Namespace dali