14991a4503d53ad89f4af4eee2d7a351fc7bd377
[platform/core/multimedia/dfs-adaptation.git] / include / dfs_parameter.h
1 /*
2  * Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
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 __DFS_PARAMETER_H__
18 #define __DFS_PARAMETER_H__
19
20 #include <cstddef>
21 #include <vector>
22 /**
23  * @file dfs_parameter.h
24  * @brief This file contains the depth parameter structure.
25  */
26
27 namespace DfsAdaptation
28 {
29         struct DfsParameter {
30                 double textureThreshold;
31                 size_t aggregationWindowWidth;
32                 size_t aggregationWindowHeight;
33                 size_t maxSpeckleSize;
34
35                 DfsParameter()
36                 {
37                         textureThreshold = 1;
38                         aggregationWindowWidth = 10;
39                         aggregationWindowWidth = 10;
40                         maxSpeckleSize = 10;
41                 }
42         };
43
44     struct DfsData {
45         void *data;
46         int type;
47         size_t width;
48         size_t height;
49         size_t stride;
50
51         std::vector<std::vector<double>> pointCloud;
52         double *pointCloudData;
53         size_t pointCloudSize;
54
55         DfsData()
56         {
57             data = nullptr;
58             type = 0;
59             width = height = stride = 0;
60         }
61     };
62
63     enum
64     {
65         DFS_DATA_TYPE_UINT8C1 = 1,
66         DFS_DATA_TYPE_UINT8C3 = 2,
67         DFS_DATA_TYPE_FLOAT32C1 = 3
68     };
69
70 }
71 #endif /* __DFS_PARAMETER_H__ */