| 1 | /* |
| 2 | Copyright 2015 - 2026 Esri |
| 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 | A local copy of the license and additional notices are located with the |
| 17 | source distribution at: |
| 18 | |
| 19 | http://github.com/Esri/lerc/ |
| 20 | |
| 21 | Contributors: Thomas Maurer |
| 22 | */ |
| 23 | |
| 24 | #ifndef IMAGE_H |
| 25 | #define IMAGE_Hcxx . . $ `src/LercLib/Lerc1Decode/Image.h:25:9`! |
| 26 | |
| 27 | #include <string> |
| 28 | #include "../Defines.h"cxx . . $ `<file>/src/LercLib/Defines.h`/ |
| 29 | |
| 30 | NAMESPACE_LERC_STARTcxx . . $ `src/LercLib/Defines.h:35:9`! |
| 31 | |
| 32 | class Imagecxx . . $ LercNS/Image# |
| 33 | { |
| 34 | public: |
| 35 | |
| 36 | virtual ~cxx . . $ LercNS/Image#`~Image`(ced63f7c635d850d).Imagecxx . . $ LercNS/Image#() {}; |
| 37 | |
| 38 | enum Typecxx . . $ LercNS/Image#Type# { BYTEcxx . . $ LercNS/Image#BYTE., RGBcxx . . $ LercNS/Image#RGB., SHORTcxx . . $ LercNS/Image#SHORT., LONGcxx . . $ LercNS/Image#LONG., FLOATcxx . . $ LercNS/Image#FLOAT., DOUBLEcxx . . $ LercNS/Image#DOUBLE., COMPLEXcxx . . $ LercNS/Image#COMPLEX., POINT3Fcxx . . $ LercNS/Image#POINT3F., CNT_Zcxx . . $ LercNS/Image#CNT_Z., CNT_ZXYcxx . . $ LercNS/Image#CNT_ZXY., Last_Type_cxx . . $ LercNS/Image#Last_Type_. }; |
| 39 | |
| 40 | bool isTypecxx . . $ LercNS/Image#isType(32dca1346ab4c9d).(Typecxx . . $ LercNS/Image#Type# t) const { return t == type_cxx . . $ LercNS/Image#type_.; } |
| 41 | Typecxx . . $ LercNS/Image#Type# getTypecxx . . $ LercNS/Image#getType(c7afdc46f753844f).() const { return type_cxx . . $ LercNS/Image#type_.; } |
| 42 | int getWidthcxx . . $ LercNS/Image#getWidth(455f465bc33b4cdf).() const { return width_cxx . . $ LercNS/Image#width_.; } |
| 43 | int getHeightcxx . . $ LercNS/Image#getHeight(455f465bc33b4cdf).() const { return height_cxx . . $ LercNS/Image#height_.; } |
| 44 | int getSizecxx . . $ LercNS/Image#getSize(455f465bc33b4cdf).() const { return width_cxx . . $ LercNS/Image#width_. * height_cxx . . $ LercNS/Image#height_.; } |
| 45 | |
| 46 | bool isInsidecxx . . $ LercNS/Image#isInside(88e30549ca55c866).(int row, int col) const { return row >= 0 && row < height_cxx . . $ LercNS/Image#height_. && col >= 0 && col < width_cxx . . $ LercNS/Image#width_.; } |
| 47 | |
| 48 | virtual stdcxx . . $ std/::stringcxx . . $ std/string# getTypeStringcxx . . $ LercNS/Image#getTypeString(219584694fe2b248).() const = 0; |
| 49 | |
| 50 | protected: |
| 51 | |
| 52 | Imagecxx . . $ LercNS/Image#Image(49f6e7a06ebc5aa8).() : type_cxx . . $ LercNS/Image#type_.(Last_Type_cxx . . $ LercNS/Image#Last_Type_.), width_cxx . . $ LercNS/Image#width_.(0), height_cxx . . $ LercNS/Image#height_.(0) {}; |
| 53 | |
| 54 | /// compare |
| 55 | bool operatorcxx . . $ LercNS/Image#`operator==`(1579293246f957a6). == (const Imagecxx . . $ LercNS/Image#& img) const { return type_cxx . . $ LercNS/Image#type_. == img.type_cxx . . $ LercNS/Image#type_. && width_cxx . . $ LercNS/Image#width_. == img.width_cxx . . $ LercNS/Image#width_. && height_cxx . . $ LercNS/Image#height_. == img.height_cxx . . $ LercNS/Image#height_.; } |
| 56 | bool operatorcxx . . $ LercNS/Image#`operator!=`(1579293246f957a6). != (const Imagecxx . . $ LercNS/Image#& img) const { return !operator==(img); }; |
| 57 | |
| 58 | Typecxx . . $ LercNS/Image#Type# type_cxx . . $ LercNS/Image#type_.; |
| 59 | int width_cxx . . $ LercNS/Image#width_., height_cxx . . $ LercNS/Image#height_.; |
| 60 | }; |
| 61 | |
| 62 | NAMESPACE_LERC_ENDcxx . . $ `src/LercLib/Defines.h:36:9`! |
| 63 | #endif |