xref: /OK3568_Linux_fs/external/camera_engine_rkaiq/rkaiq/hwi/isp20/NrStreamProcUnit.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /*
2  *  Copyright (c) 2019 Rockchip Corporation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 #ifndef _NR_STREAM_PROC_UNIT_H_
18 #define _NR_STREAM_PROC_UNIT_H_
19 #include "NrStatsStream.h"
20 #include "rk_aiq_pool.h"
21 #include "Isp20Params.h"
22 
23 using namespace XCam;
24 namespace RkCam {
25 
26 class CamHwIsp20;
27 class NrStreamProcUnit
28 {
29 public:
30     NrStreamProcUnit               (const rk_sensor_full_info_t *s_info);
31     virtual ~NrStreamProcUnit      ();
32     void set_devices				(CamHwIsp20 *camHw, SmartPtr<V4l2SubDevice> isppdev);
33     void start                  ();
34     void stop                   ();
35     void pause                  ();
36     void resume                 ();
37     XCamReturn config_params(uint32_t frameId, SmartPtr<cam3aResult>& result);
38 protected:
39     XCamReturn configToDrv(uint32_t frameId);
40 
41 private:
42     XCAM_DEAD_COPY (NrStreamProcUnit);
43     SmartPtr<V4l2Device> mNrStatsDev;
44     SmartPtr<V4l2Device> mNrParamsDev;
45     SmartPtr<RKStream> mNrParamStream;
46     SmartPtr<NrStatsStream> mNrStatsStream;
47     CamHwIsp20 *mCamHw;
48     SmartPtr<V4l2SubDevice> mIsppSubDev;
49     SmartPtr<IspParamsAssembler> mParamsAssembler;
50     struct rkispp_params_nrcfg last_ispp_nr_params;
51 };
52 
53 
54 }
55 #endif
56