diff options
author | Xu Yang <yangxu@codeaurora.org> | 2017-11-20 09:58:11 +0800 |
---|---|---|
committer | Ping Li <pingli@codeaurora.org> | 2018-04-27 12:38:54 -0700 |
commit | 32e58c217cf62659a7e5ee10cecf5fc79d59b950 (patch) | |
tree | aba1c7af59e61446a6cd6149cf1dc00d575b9491 /libdrmutils | |
parent | cbbc57eeeff407de6a0c5fa59ccc4da31a2a6016 (diff) |
sdm: Initial change for Dpps interface
Support DppsInterface in SDM to create and destroy Dpps server.
And DppsPropIntf provides functions to set and get Dpps properties.
CRs-Fixed: 2232100
Change-Id: I0ecf93ef994ba94ae1baf4f97031e257d30d3dcd
Diffstat (limited to 'libdrmutils')
-rw-r--r-- | libdrmutils/drm_interface.h | 86 |
1 files changed, 75 insertions, 11 deletions
diff --git a/libdrmutils/drm_interface.h b/libdrmutils/drm_interface.h index 2aeb337b..b552a578 100644 --- a/libdrmutils/drm_interface.h +++ b/libdrmutils/drm_interface.h @@ -351,13 +351,20 @@ enum struct DRMOps { * Arg: uint32_t - Connector ID * DRMPPFeatureInfo * - PP feature data pointer */ - CONNECTOR_SET_POST_PROC, + CONNECTOR_SET_POST_PROC, /* * Op: Sets connector hdr metadata * Arg: uint32_t - Connector ID * drm_msm_ext_hdr_metadata - hdr_metadata */ CONNECTOR_SET_HDR_METADATA, + /* + * Op: Cache Dpps features. + * Arg: uint32_t - Object ID + uint32_t - Feature ID + * uint64_t - Pointer to feature config data + */ + DPPS_CACHE_FEATURE, }; enum struct DRMRotation { @@ -601,6 +608,56 @@ struct DRMPPFeatureInfo { uint32_t object_type; }; +enum DRMDPPSFeatureID { + // Ad4 properties + kFeatureAd4Mode, + kFeatureAd4Init, + kFeatureAd4Cfg, + kFeatureAd4Input, + kFeatureAd4Backlight, + kFeatureAd4Assertiveness, + kFeatureAd4ManualStrength, + // ABA properties + kFeatureAbaHistCtrl, + kFeatureAbaHistIRQ, + kFeatureAbaLut, + // BL scale properties + kFeatureAd4BlScale, + kFeatureBacklightScale, + // Events + kFeaturePowerEvent, + kFeatureAbaHistEvent, + kFeatureBackLightEvent, + kFeatureAdAttBlEvent, + // Insert features above + kDppsFeaturesMax, +}; + +struct DRMDppsFeatureInfo { + DRMDPPSFeatureID id; + uint32_t version; +}; + +enum AD4Modes { + kAd4Off, + kAd4AutoStrength, + kAd4Calibration, + kAd4Manual, + kAd4ModeMax, +}; + +enum HistModes { + kHistDisabled, + kHistEnabled, +}; + +struct DRMDppsEventInfo { + uint32_t object_type; + uint32_t event_type; + int drm_fd; + bool enable; +}; + enum DRMCscType { kCscYuv2Rgb601L, kCscYuv2Rgb601FR, @@ -638,16 +695,16 @@ enum struct DRMMultiRectMode { }; struct DRMSolidfillStage { - DRMRect bounding_rect {}; - bool is_exclusion_rect = false; - uint32_t color = 0xff000000; // in 8bit argb - uint32_t red = 0; - uint32_t blue = 0; - uint32_t green = 0; - uint32_t alpha = 0xff; - uint32_t color_bit_depth = 0; - uint32_t z_order = 0; - uint32_t plane_alpha = 0xff; + DRMRect bounding_rect {}; + bool is_exclusion_rect = false; + uint32_t color = 0xff000000; // in 8bit argb + uint32_t red = 0; + uint32_t blue = 0; + uint32_t green = 0; + uint32_t alpha = 0xff; + uint32_t color_bit_depth = 0; + uint32_t z_order = 0; + uint32_t plane_alpha = 0xff; }; /* DRM Atomic Request Property Set. @@ -767,6 +824,13 @@ class DRMManagerInterface { * [return]: Error code if the API fails, 0 on success. */ virtual int SetScalerLUT(const DRMScalerLUTInfo &lut_info) = 0; + + /* + * Get the DPPS feature info + * [input]: Dpps feature id, info->id + * [output]: Dpps feature version, info->version + */ + virtual void GetDppsFeatureInfo(DRMDppsFeatureInfo *info) = 0; }; } // namespace sde_drm |