use modern construct 'override' in the derive class.
[platform/core/uifw/dali-core.git] / dali / internal / render / data-providers / node-data-provider.h
1 #ifndef DALI_INTERNAL_SCENE_GRAPH_NODE_DATA_PROVIDER_H
2 #define DALI_INTERNAL_SCENE_GRAPH_NODE_DATA_PROVIDER_H
3
4 /*
5  * Copyright (c) 2019 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  */
20
21 #include <dali/internal/render/data-providers/uniform-map-data-provider.h>
22
23 namespace Dali
24 {
25 struct Vector4;
26 class Matrix;
27
28 namespace Internal
29 {
30 namespace SceneGraph
31 {
32
33 /**
34  * An interface to provide data for a Renderer
35  */
36 class NodeDataProvider : UniformMapDataProvider
37 {
38 public:
39
40   /**
41    * Constructor. Nothing to do as a pure interface.
42    */
43   NodeDataProvider() { }
44
45   /**
46    * @param bufferIndex to use
47    * @return a reference to the model matrix
48    */
49   virtual const Matrix& GetModelMatrix( BufferIndex bufferIndex ) const = 0;
50
51   /**
52    * @param bufferIndex to use
53    * @return a reference to the color
54    */
55   virtual const Vector4& GetRenderColor( BufferIndex bufferIndex ) const = 0;
56
57   /**
58    * @copydoc Dali::Internal::SceneGraph::UniformMapDataProvider::GetUniformMapChanged()
59    */
60   bool GetUniformMapChanged( BufferIndex bufferIndex ) const override = 0;
61
62   /**
63    * @copydoc Dali::Internal::SceneGraph::UniformMapDataProvider::GetUniformMap()
64    */
65   const CollectedUniformMap& GetUniformMap( BufferIndex bufferIndex ) const override = 0;
66
67 protected:
68   /**
69    * Virtual destructor, this is an interface, no deletion through this interface
70    */
71   ~NodeDataProvider() override { }
72 };
73
74 } // SceneGraph
75 } // Internal
76 } // Dali
77
78 #endif // DALI_INTERNAL_SCENE_GRAPH_NODE_DATA_PROVIDER_H