display: initialize viewFrame info for external displays

- At the initialization, set the viewFrame info for the external
  and virtual displays to its resolution.
- It will be modified later based on the display projection

Change-Id: I25b74dcd375cb15386d5dad6f6d3730b15969f8f
This commit is contained in:
Arun Kumar K.R
2014-06-25 00:53:34 -07:00
parent bd95ab1262
commit db7d83a514
2 changed files with 14 additions and 0 deletions

View File

@@ -194,6 +194,13 @@ void VirtualDisplay::setAttributes() {
setDownScaleMode(maxArea);
}
//Initialize the display viewFrame info
mHwcContext->mViewFrame[HWC_DISPLAY_VIRTUAL].left = 0;
mHwcContext->mViewFrame[HWC_DISPLAY_VIRTUAL].top = 0;
mHwcContext->mViewFrame[HWC_DISPLAY_VIRTUAL].right =
(int)mHwcContext->dpyAttr[HWC_DISPLAY_VIRTUAL].xres;
mHwcContext->mViewFrame[HWC_DISPLAY_VIRTUAL].bottom =
(int)mHwcContext->dpyAttr[HWC_DISPLAY_VIRTUAL].yres;
mHwcContext->dpyAttr[HWC_DISPLAY_VIRTUAL].vsync_period =
1000000000l /60;
ALOGD_IF(DEBUG,"%s: Setting Virtual Attr: res(%d x %d)",__FUNCTION__,