1 /* 2 * Copyright (c) 2024, Intel Corporation 3 * 4 * Permission is hereby granted, free of charge, to any person obtaining a 5 * copy of this software and associated documentation files (the "Software"), 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 10 * 11 * The above copyright notice and this permission notice shall be included 12 * in all copies or substantial portions of the Software. 13 * 14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 15 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 17 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 18 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 20 * OTHER DEALINGS IN THE SOFTWARE. 21 */ 22 23 //! 24 //! \file surface_type.h 25 //! \brief Defines the common interface for vp features manager 26 //! \details The vp manager is further sub-divided by vp type 27 //! this file is for the base interface which is shared by all components. 28 //! 29 #ifndef __SURFACE_TYPE_H__ 30 #define __SURFACE_TYPE_H__ 31 32 namespace vp 33 { 34 // Need to make sure maximum size <256 35 // If exceed 256, need to reserve extra bit 36 #define SURFACETYPE_SIZE32 31 37 #define SURFACETYPE_SIZE16 15 38 #define SURFACETYPE_SIZE5 4 39 #define SURFACETYPE_SIZE10 9 40 #define SURFACETYPE_SIZE8 7 41 #define SURFACETYPE_SIZE64 63 42 #define SURFACETYPE_SIZE4 3 43 #define SURFACETYPE_SIZE3 2 44 #define GFSURFACE_COUNT 8 45 #define MOTION_CHANNEL 3 46 #define MAX_MODELSURFACE_COUNT 85 47 48 #define SUFACE_MASK 0xffffff00 49 #define SUFACE_TYPE_ASSIGNED(type) (((type)&SUFACE_MASK) >> 8) 50 51 enum SurfaceType 52 { 53 SurfaceTypeInvalid = 0x0, 54 SurfaceTypeVeboxInput = 0x100, 55 SurfaceTypeVeboxPreviousInput = 0x200, 56 SurfaceTypeDNOutput = 0x300, 57 SurfaceTypeVeboxCurrentOutput = 0x400, 58 SurfaceTypeVeboxPreviousOutput = 0x500, 59 SurfaceTypeScalar = 0x600, 60 SurfaceTypeSTMMIn = 0x700, 61 SurfaceTypeSTMMOut = 0x800, 62 SurfaceTypeACEHistory = 0x900, 63 SurfaceTypeFMDHistory = 0xa00, 64 SurfaceTypeLaceAceRGBHistogram = 0xb00, 65 SurfaceTypeLaceLut = 0xc00, 66 SurfaceTypeStatistics = 0xd00, 67 SurfaceTypeSkinScore = 0xe00, 68 SurfaceType3DLut = 0xf00, 69 SurfaceType1k1dLut = 0x1000, 70 SurfaceType1dLutHDR = 0x1100, 71 SurfaceTypeAlphaOrVignette = 0x1200, 72 SurfaceTypeVeboxStateHeap_Drv = 0x1300, 73 SurfaceTypeVeboxStateHeap_Knr = 0x1400, 74 SurfaceTypeAutoDNNoiseLevel = 0x1500, // with kernel path needed 75 SurfaceTypeAutoDNSpatialConfig = 0x1600, 76 SurfaceTypeRenderInput = 0x1700, 77 SurfaceTypeRenderOutput = 0x1800, 78 SurfaceTypeAggregatedHistogram = 0x1900, 79 SurfaceTypeFrameHistogram = 0x1a00, 80 SurfaceTypeStdStatistics = 0x1b00, 81 SurfaceTypePwlfIn = 0x1c00, 82 SurfaceTypePwlfOut = 0x1d00, 83 SurfaceTypeWeitCoef = 0x1e00, 84 SurfaceTypGlobalToneMappingCurveLUT = 0x1f00, 85 86 // FC 87 SurfaceTypeFcInputLayer0 = 0x2000, 88 SurfaceTypeFcInputLayerMax = SurfaceTypeFcInputLayer0 + SURFACETYPE_SIZE8, 89 SurfaceTypeFcInputLayer0Field1Dual = 0x2100, 90 SurfaceTypeFcInputLayerMaxField1Dual = SurfaceTypeFcInputLayer0Field1Dual + SURFACETYPE_SIZE8, 91 SurfaceTypeFcTarget0 = 0x2200, 92 SurfaceTypeFcTarget1 = 0x2300, 93 SurfaceTypeFcCscCoeff = 0x2400, 94 SurfaceTypeDecompressionSync = 0x2500, 95 SurfaceTypeFcIntermediaInput = 0x2510, 96 97 // 3DLut Kernel 98 SurfaceType3DLut2D = 0x2600, 99 SurfaceType3DLutCoef = 0x2700, 100 101 // HVS Kernel 102 SurfaceTypeHVSTable = 0x2800, 103 104 // HDR Kernel 105 SurfaceTypeHdrInputLayer0 = 0x2900, 106 SurfaceTypeHdrInputLayerMax = SurfaceTypeHdrInputLayer0 + SURFACETYPE_SIZE8, 107 SurfaceTypeHdrOETF1DLUTSurface0 = 0x2a00, 108 SurfaceTypeHdrOETF1DLUTSurfaceMax = SurfaceTypeHdrOETF1DLUTSurface0 + SURFACETYPE_SIZE8, 109 SurfaceTypeHdrCRI3DLUTSurface0 = 0x2b00, 110 SurfaceTypeHdrCRI3DLUTSurfaceMax = SurfaceTypeHdrCRI3DLUTSurface0 + SURFACETYPE_SIZE8, 111 SurfaceTypeHdrTarget0 = 0x2c00, 112 SurfaceTypeHdrCoeff = 0x2d00, 113 SurfaceTypeHdrAutoModeCoeff = 0x2e00, 114 SurfaceTypeHdrAutoModeIirTempSurface = 0x2f00, 115 SurfaceTypeInnerTileConvertInput = 0x3000, // Intermedia surface between VESFC states and tile convert states inside single batchbuffer. 116 NumberOfSurfaceTypeBase = 0x3100, 117 118 #ifdef _MEDIA_RESERVED 119 #include "surface_type_ext.h" 120 #endif 121 NumberOfSurfaceType 122 }; 123 } // namespace vp 124 #endif // !__SURFACE_TYPE_H__ 125