1 /* 2 * RkAiqConfigTranslator.h 3 * 4 * Copyright (c) 2019 Rockchip Corporation 5 * 6 * Licensed under the Apache License, Version 2.0 (the "License"); 7 * you may not use this file except in compliance with the License. 8 * You may obtain a copy of the License at 9 * 10 * http://www.apache.org/licenses/LICENSE-2.0 11 * 12 * Unless required by applicable law or agreed to in writing, software 13 * distributed under the License is distributed on an "AS IS" BASIS, 14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 * See the License for the specific language governing permissions and 16 * limitations under the License. 17 * 18 */ 19 20 #ifndef _RK_AIQ_RESOURCE_TRANSLATOR_H_ 21 #define _RK_AIQ_RESOURCE_TRANSLATOR_H_ 22 23 #include "IRkAiqResourceTranslator.h" 24 #include "rk_aiq_types.h" 25 26 namespace RkCam { 27 28 class RkAiqResourceTranslator 29 : public IRkAiqResourceTranslator 30 { 31 public: 32 RkAiqResourceTranslator () = default; 33 virtual ~RkAiqResourceTranslator () = default; 34 35 virtual XCamReturn translateIspStats(const SmartPtr<VideoBuffer>& from, 36 SmartPtr<RkAiqIspStatsIntProxy>& to, 37 const SmartPtr<RkAiqAecStatsProxy>& aecStat, 38 const SmartPtr<RkAiqAwbStatsProxy>& awbStat, 39 const SmartPtr<RkAiqAfStatsProxy>& afStat, 40 const SmartPtr<RkAiqAtmoStatsProxy>& tmoStat, 41 const SmartPtr<RkAiqAdehazeStatsProxy>& dehazeStat); 42 virtual XCamReturn translateAecStats(const SmartPtr<VideoBuffer>& from, 43 SmartPtr<RkAiqAecStatsProxy>& to); 44 virtual XCamReturn translateAwbStats(const SmartPtr<VideoBuffer>& from, 45 SmartPtr<RkAiqAwbStatsProxy>& to); 46 virtual XCamReturn translateAfStats(const SmartPtr<VideoBuffer>& from, 47 SmartPtr<RkAiqAfStatsProxy>& to); 48 virtual XCamReturn translateOrbStats(const SmartPtr<VideoBuffer>& from, 49 SmartPtr<RkAiqOrbStatsProxy>& to); 50 virtual XCamReturn translateAtmoStats(const SmartPtr<VideoBuffer>& from, 51 SmartPtr<RkAiqAtmoStatsProxy>& to); 52 #if RKAIQ_HAVE_DEHAZE_V10 53 virtual XCamReturn translateAdehazeStats(const SmartPtr<VideoBuffer>& from, 54 SmartPtr<RkAiqAdehazeStatsProxy>& to); 55 #endif 56 #if RKAIQ_HAVE_PDAF 57 virtual XCamReturn translatePdafStats(const SmartPtr<VideoBuffer>& from, 58 SmartPtr<RkAiqPdafStatsProxy>& to, bool sns_mirror); 59 #endif 60 61 virtual XCamReturn getParams(const SmartPtr<VideoBuffer>& from); 62 virtual void releaseParams(); 63 protected: 64 rkisp_effect_params_v20 _ispParams; 65 SmartPtr<RkAiqSensorExpParamsProxy> _expParams; 66 private: 67 XCAM_DEAD_COPY (RkAiqResourceTranslator); 68 }; 69 70 } 71 72 #endif //_RK_AIQ_CONFIG_TRANSLATOR_H_ 73