1 #ifndef DALI_INTERNAL_SCENE_GRAPH_RENDER_DATA_PROVIDER_H
2 #define DALI_INTERNAL_SCENE_GRAPH_RENDER_DATA_PROVIDER_H
5 * Copyright (c) 2022 Samsung Electronics Co., Ltd.
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
11 * http://www.apache.org/licenses/LICENSE-2.0
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.
21 #include <dali/internal/render/data-providers/uniform-map-data-provider.h>
22 #include <dali/public-api/common/dali-vector.h>
28 struct BlendingOptions;
42 * Wraps all the data providers for the renderer. This allows the
43 * individual providers to change connections in the update thread without affecting
44 * the current render. It essentially provides double buffering of the
45 * provider accessor through the message system. It does not take ownership
48 class RenderDataProvider
54 virtual ~RenderDataProvider() = default;
58 * Get the uniform map data provider
60 virtual const UniformMapDataProvider& GetUniformMapDataProvider() const = 0;
66 virtual const Shader& GetShader() const = 0;
69 * Returns the list of samplers
70 * @return The list of samplers
72 virtual const Dali::Vector<Render::Sampler*>* GetSamplers() const = 0;
75 * Returns the list of Textures
76 * @return The list of Textures
78 virtual const Dali::Vector<Render::Texture*>* GetTextures() const = 0;
82 * @param[in] bufferIndex The current buffer index.
85 virtual float GetOpacity(BufferIndex bufferIndex) const = 0;
88 * @brief Retrieve if the render data is updated
89 * @return An updated flag
91 virtual bool IsUpdated() const = 0;
94 * @brief Get the update area after visual properties applied.
95 * @param[in] bufferIndex The current buffer index.
96 * @param[in] originalUpdateArea The original update area before apply the visual properties.
97 * @return The recalculated size after visual properties applied.
99 virtual Vector4 GetVisualTransformedUpdateArea(BufferIndex bufferIndex, const Vector4& originalUpdateArea) noexcept = 0;
102 } // namespace SceneGraph
103 } // namespace Internal
106 #endif // DALI_INTERNAL_SCENE_GRAPH_RENDER_DATA_PROVIDER_H