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 IMAGE_CHAIN_H 17 #define IMAGE_CHAIN_H 18 19 #include <memory> 20 #include "algo_filter.h" 21 #include "input.h" 22 23 namespace OHOS { 24 namespace Rosen { 25 class ImageChain { 26 public: 27 ImageChain(std::vector<std::shared_ptr<Input>> inputs); ~ImageChain()28 virtual ~ImageChain() {}; 29 bool Render(); 30 31 private: 32 void CreatTexture(unsigned int& TextureID); 33 bool SeriesRendering(ProcessData& data); 34 bool ParallelRendering(); 35 bool flagSeries_ = false; 36 unsigned int frameBufferID_; 37 unsigned int srcTextureID_; 38 unsigned int dstTextureID_; 39 std::vector<std::shared_ptr<Input>> inputs_; 40 }; 41 } // namespace Rosen 42 } // namespace OHOS 43 #endif // IMAGE_CHAIN_H 44