Lines Matching refs:ctx

51 QClient::QClient(hwc_context_t *ctx) : mHwcContext(ctx),  in QClient()  argument
52 mMPDeathNotifier(new MPDeathNotifier(ctx)) in QClient()
62 static void securing(hwc_context_t *ctx, uint32_t startEnd) { in securing() argument
67 ctx->mDrawLock.lock(); in securing()
68 ctx->mSecuring = startEnd; in securing()
71 ctx->mSecureMode = true; in securing()
72 ctx->mDrawLock.unlock(); in securing()
74 if(ctx->proc) in securing()
75 ctx->proc->invalidate(ctx->proc); in securing()
78 static void unsecuring(hwc_context_t *ctx, uint32_t startEnd) { in unsecuring() argument
79 ctx->mDrawLock.lock(); in unsecuring()
80 ctx->mSecuring = startEnd; in unsecuring()
83 ctx->mSecureMode = false; in unsecuring()
84 ctx->mDrawLock.unlock(); in unsecuring()
86 if(ctx->proc) in unsecuring()
87 ctx->proc->invalidate(ctx->proc); in unsecuring()
100 static android::status_t screenRefresh(hwc_context_t *ctx) { in screenRefresh() argument
102 if(ctx->proc) { in screenRefresh()
103 ctx->proc->invalidate(ctx->proc); in screenRefresh()
109 static void setExtOrientation(hwc_context_t *ctx, uint32_t orientation) { in setExtOrientation() argument
110 ctx->mExtOrientation = orientation; in setExtOrientation()
113 static void isExternalConnected(hwc_context_t* ctx, Parcel* outParcel) { in isExternalConnected() argument
115 connected = ctx->dpyAttr[HWC_DISPLAY_EXTERNAL].connected ? 1 : 0; in isExternalConnected()
119 static void getDisplayAttributes(hwc_context_t* ctx, const Parcel* inParcel, in getDisplayAttributes() argument
122 outParcel->writeInt32(ctx->dpyAttr[dpy].vsync_period); in getDisplayAttributes()
123 if (ctx->dpyAttr[dpy].customFBSize) { in getDisplayAttributes()
124 outParcel->writeInt32(ctx->dpyAttr[dpy].xres_new); in getDisplayAttributes()
125 outParcel->writeInt32(ctx->dpyAttr[dpy].yres_new); in getDisplayAttributes()
127 outParcel->writeInt32(ctx->dpyAttr[dpy].xres); in getDisplayAttributes()
128 outParcel->writeInt32(ctx->dpyAttr[dpy].yres); in getDisplayAttributes()
130 outParcel->writeFloat(ctx->dpyAttr[dpy].xdpi); in getDisplayAttributes()
131 outParcel->writeFloat(ctx->dpyAttr[dpy].ydpi); in getDisplayAttributes()
133 outParcel->writeInt32(ctx->mMDP.panel); in getDisplayAttributes()
147 static void setBufferMirrorMode(hwc_context_t *ctx, uint32_t enable) { in setBufferMirrorMode() argument
148 ctx->mBufferMirrorMode = enable; in setBufferMirrorMode()
151 static status_t getDisplayVisibleRegion(hwc_context_t* ctx, int dpy, in getDisplayVisibleRegion() argument
155 Locker::Autolock _sl(ctx->mDrawLock); in getDisplayVisibleRegion()
156 if(dpy && (ctx->mExtOrientation || ctx->mBufferMirrorMode)) { in getDisplayVisibleRegion()
159 outParcel->writeInt32(ctx->dpyAttr[dpy].mDstRect.left); in getDisplayVisibleRegion()
160 outParcel->writeInt32(ctx->dpyAttr[dpy].mDstRect.top); in getDisplayVisibleRegion()
161 outParcel->writeInt32(ctx->dpyAttr[dpy].mDstRect.right); in getDisplayVisibleRegion()
162 outParcel->writeInt32(ctx->dpyAttr[dpy].mDstRect.bottom); in getDisplayVisibleRegion()
164 outParcel->writeInt32(ctx->mViewFrame[dpy].left); in getDisplayVisibleRegion()
165 outParcel->writeInt32(ctx->mViewFrame[dpy].top); in getDisplayVisibleRegion()
166 outParcel->writeInt32(ctx->mViewFrame[dpy].right); in getDisplayVisibleRegion()
167 outParcel->writeInt32(ctx->mViewFrame[dpy].bottom); in getDisplayVisibleRegion()
177 static void setSecondaryDisplayStatus(hwc_context_t *ctx, in setSecondaryDisplayStatus() argument
186 ctx->mWfdSyncLock.lock(); in setSecondaryDisplayStatus()
187 ctx->mWfdSyncLock.signal(); in setSecondaryDisplayStatus()
188 ctx->mWfdSyncLock.unlock(); in setSecondaryDisplayStatus()
190 handle_pause(ctx, dpy); in setSecondaryDisplayStatus()
192 handle_resume(ctx, dpy); in setSecondaryDisplayStatus()
201 static status_t setViewFrame(hwc_context_t* ctx, const Parcel* inParcel) { in setViewFrame() argument
204 Locker::Autolock _sl(ctx->mDrawLock); in setViewFrame()
205 ctx->mViewFrame[dpy].left = inParcel->readInt32(); in setViewFrame()
206 ctx->mViewFrame[dpy].top = inParcel->readInt32(); in setViewFrame()
207 ctx->mViewFrame[dpy].right = inParcel->readInt32(); in setViewFrame()
208 ctx->mViewFrame[dpy].bottom = inParcel->readInt32(); in setViewFrame()
211 ctx->mViewFrame[dpy].left, ctx->mViewFrame[dpy].top, in setViewFrame()
212 ctx->mViewFrame[dpy].right, ctx->mViewFrame[dpy].bottom); in setViewFrame()
220 static void toggleDynamicDebug(hwc_context_t* ctx, const Parcel* inParcel) { in toggleDynamicDebug() argument
225 Locker::Autolock _sl(ctx->mDrawLock); in toggleDynamicDebug()
234 ctx->vstate.debug = enable; in toggleDynamicDebug()
248 static void setIdleTimeout(hwc_context_t* ctx, const Parcel* inParcel) { in setIdleTimeout() argument
251 Locker::Autolock _sl(ctx->mDrawLock); in setIdleTimeout()
255 static void setMaxPipesPerMixer(hwc_context_t* ctx, const Parcel* inParcel) { in setMaxPipesPerMixer() argument
258 Locker::Autolock _sl(ctx->mDrawLock); in setMaxPipesPerMixer()
262 static void toggleBWC(hwc_context_t* ctx, const Parcel* inParcel) { in toggleBWC() argument
265 Locker::Autolock _sl(ctx->mDrawLock); in toggleBWC()
266 ctx->mBWCEnabled = (bool) enable; in toggleBWC()
273 static void configureDynRefreshRate(hwc_context_t* ctx, in configureDynRefreshRate() argument
281 Locker::Autolock _sl(ctx->mDrawLock); in configureDynRefreshRate()
285 ctx->mUseMetaDataRefreshRate = false; in configureDynRefreshRate()
286 setRefreshRate(ctx, dpy, ctx->dpyAttr[dpy].refreshRate); in configureDynRefreshRate()
289 ctx->mUseMetaDataRefreshRate = true; in configureDynRefreshRate()
290 setRefreshRate(ctx, dpy, ctx->dpyAttr[dpy].refreshRate); in configureDynRefreshRate()
293 if(ctx->mUseMetaDataRefreshRate) in configureDynRefreshRate()
300 setRefreshRate(ctx, dpy, rate); in configureDynRefreshRate()
315 static status_t setPartialUpdatePref(hwc_context_t *ctx, uint32_t enable) { in setPartialUpdatePref() argument
317 if(qhwc::MDPComp::setPartialUpdatePref(ctx, (bool)enable) < 0) in setPartialUpdatePref()
322 static void toggleScreenUpdate(hwc_context_t* ctx, uint32_t on) { in toggleScreenUpdate() argument
325 ctx->mDrawLock.lock(); in toggleScreenUpdate()
326 ctx->dpyAttr[HWC_DISPLAY_PRIMARY].isPause = true; in toggleScreenUpdate()
327 ctx->mOverlay->configBegin(); in toggleScreenUpdate()
328 ctx->mOverlay->configDone(); in toggleScreenUpdate()
329 ctx->mRotMgr->clear(); in toggleScreenUpdate()
330 if(!Overlay::displayCommit(ctx->dpyAttr[0].fd)) { in toggleScreenUpdate()
333 ctx->mDrawLock.unlock(); in toggleScreenUpdate()
335 ctx->mDrawLock.lock(); in toggleScreenUpdate()
336 ctx->dpyAttr[HWC_DISPLAY_PRIMARY].isPause = false; in toggleScreenUpdate()
337 ctx->mDrawLock.unlock(); in toggleScreenUpdate()
338 ctx->proc->invalidate(ctx->proc); in toggleScreenUpdate()
342 static void applyModeById(hwc_context_t* ctx, int32_t modeId) { in applyModeById() argument
343 int err = ctx->mColorMode->applyModeByID(modeId); in applyModeById()
347 ctx->proc->invalidate(ctx->proc); in applyModeById()