• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2022 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef RENDER_POSTPROCESS_RENDER_POST_PROCESS_COMBINED_H
17 #define RENDER_POSTPROCESS_RENDER_POST_PROCESS_COMBINED_H
18 
19 #include <base/math/vector.h>
20 #include <base/util/uid.h>
21 #include <core/plugin/intf_interface.h>
22 #include <core/plugin/intf_interface_helper.h>
23 #include <core/property/intf_property_handle.h>
24 #include <render/namespace.h>
25 #include <render/nodecontext/intf_render_node.h>
26 #include <render/nodecontext/intf_render_post_process.h>
27 #include <render/nodecontext/intf_render_post_process_node.h>
28 
29 #include "render_post_process_combined_node.h"
30 
RENDER_BEGIN_NAMESPACE()31 RENDER_BEGIN_NAMESPACE()
32 class RenderPostProcessCombined final : public CORE_NS::IInterfaceHelper<RENDER_NS::IRenderPostProcess> {
33 public:
34     static constexpr auto UID = BASE_NS::Uid("b183dbd7-23ce-4eb0-948a-a17519f6f98c");
35 
36     RenderPostProcessCombined();
37     ~RenderPostProcessCombined() override = default;
38 
39     CORE_NS::IPropertyHandle* GetProperties() override;
40 
41     BASE_NS::Uid GetRenderPostProcessNodeUid() override
42     {
43         return RenderPostProcessCombinedNode::UID;
44     }
45 
46     void SetData(BASE_NS::array_view<const uint8_t> data) override;
47     BASE_NS::array_view<const uint8_t> GetData() const override;
48 
49     // direct access in render nodes
50     RenderPostProcessCombinedNode::EffectProperties propertiesData;
51 
52 private:
53     CORE_NS::PropertyApiImpl<RenderPostProcessCombinedNode::EffectProperties> properties_;
54 };
55 RENDER_END_NAMESPACE()
56 
57 #endif // RENDER_POSTPROCESS_RENDER_POST_PROCESS_COMBINED_H