Loading libs/gui/Surface.cpp +8 −3 Original line number Diff line number Diff line Loading @@ -351,13 +351,13 @@ int Surface::query(int what, int* value) const { // ---------------------------------------------------------------------------- status_t Surface::lock(SurfaceInfo* other, Region* dirtyIn) { status_t Surface::lock(SurfaceInfo* other, Region* inOutDirtyRegion) { ANativeWindow_Buffer outBuffer; ARect temp; ARect* inOutDirtyBounds = NULL; if (dirtyIn) { temp = dirtyIn->getBounds(); if (inOutDirtyRegion) { temp = inOutDirtyRegion->getBounds(); inOutDirtyBounds = &temp; } Loading @@ -371,6 +371,11 @@ status_t Surface::lock(SurfaceInfo* other, Region* dirtyIn) { other->format = uint32_t(outBuffer.format); other->bits = outBuffer.bits; } if (inOutDirtyRegion) { inOutDirtyRegion->set( static_cast<Rect const&>(temp) ); } return err; } Loading services/surfaceflinger/Layer.cpp +13 −2 Original line number Diff line number Diff line Loading @@ -538,9 +538,9 @@ void Layer::dump(String8& result, char* buffer, size_t SIZE) const snprintf(buffer, SIZE, " " "format=%2d, activeBuffer=[%4ux%4u:%4u,%3X]," " freezeLock=%p, queued-frames=%d\n", " freezeLock=%p, transform-hint=0x%02x, queued-frames=%d\n", mFormat, w0, h0, s0,f0, getFreezeLock().get(), mQueuedFrames); getFreezeLock().get(), getTransformHint(), mQueuedFrames); result.append(buffer); Loading @@ -559,6 +559,17 @@ uint32_t Layer::getEffectiveUsage(uint32_t usage) const return usage; } uint32_t Layer::getTransformHint() const { uint32_t orientation = 0; if (!mFlinger->mDebugDisableTransformHint) { orientation = getOrientation(); if (orientation & Transform::ROT_INVALID) { orientation = 0; } } return orientation; } // --------------------------------------------------------------------------- Loading services/surfaceflinger/Layer.h +1 −0 Original line number Diff line number Diff line Loading @@ -89,6 +89,7 @@ private: void onFrameQueued(); virtual sp<ISurface> createSurface(); uint32_t getEffectiveUsage(uint32_t usage) const; uint32_t getTransformHint() const; bool isCropped() const; static bool getOpacityForFormat(uint32_t format); Loading services/surfaceflinger/SurfaceFlinger.cpp +7 −0 Original line number Diff line number Diff line Loading @@ -93,6 +93,7 @@ SurfaceFlinger::SurfaceFlinger() mDebugBackground(0), mDebugDDMS(0), mDebugDisableHWC(0), mDebugDisableTransformHint(0), mDebugInSwapBuffers(0), mLastSwapBufferTime(0), mDebugInTransaction(0), Loading Loading @@ -1689,6 +1690,12 @@ status_t SurfaceFlinger::onTransact( invalidateHwcGeometry(); repaintEverything(); return NO_ERROR; case 1009: // toggle use of transform hint n = data.readInt32(); mDebugDisableTransformHint = n ? 1 : 0; invalidateHwcGeometry(); repaintEverything(); return NO_ERROR; case 1010: // interrogate. reply->writeInt32(0); reply->writeInt32(0); Loading services/surfaceflinger/SurfaceFlinger.h +1 −0 Original line number Diff line number Diff line Loading @@ -374,6 +374,7 @@ private: int mDebugBackground; int mDebugDDMS; int mDebugDisableHWC; int mDebugDisableTransformHint; volatile nsecs_t mDebugInSwapBuffers; nsecs_t mLastSwapBufferTime; volatile nsecs_t mDebugInTransaction; Loading Loading
libs/gui/Surface.cpp +8 −3 Original line number Diff line number Diff line Loading @@ -351,13 +351,13 @@ int Surface::query(int what, int* value) const { // ---------------------------------------------------------------------------- status_t Surface::lock(SurfaceInfo* other, Region* dirtyIn) { status_t Surface::lock(SurfaceInfo* other, Region* inOutDirtyRegion) { ANativeWindow_Buffer outBuffer; ARect temp; ARect* inOutDirtyBounds = NULL; if (dirtyIn) { temp = dirtyIn->getBounds(); if (inOutDirtyRegion) { temp = inOutDirtyRegion->getBounds(); inOutDirtyBounds = &temp; } Loading @@ -371,6 +371,11 @@ status_t Surface::lock(SurfaceInfo* other, Region* dirtyIn) { other->format = uint32_t(outBuffer.format); other->bits = outBuffer.bits; } if (inOutDirtyRegion) { inOutDirtyRegion->set( static_cast<Rect const&>(temp) ); } return err; } Loading
services/surfaceflinger/Layer.cpp +13 −2 Original line number Diff line number Diff line Loading @@ -538,9 +538,9 @@ void Layer::dump(String8& result, char* buffer, size_t SIZE) const snprintf(buffer, SIZE, " " "format=%2d, activeBuffer=[%4ux%4u:%4u,%3X]," " freezeLock=%p, queued-frames=%d\n", " freezeLock=%p, transform-hint=0x%02x, queued-frames=%d\n", mFormat, w0, h0, s0,f0, getFreezeLock().get(), mQueuedFrames); getFreezeLock().get(), getTransformHint(), mQueuedFrames); result.append(buffer); Loading @@ -559,6 +559,17 @@ uint32_t Layer::getEffectiveUsage(uint32_t usage) const return usage; } uint32_t Layer::getTransformHint() const { uint32_t orientation = 0; if (!mFlinger->mDebugDisableTransformHint) { orientation = getOrientation(); if (orientation & Transform::ROT_INVALID) { orientation = 0; } } return orientation; } // --------------------------------------------------------------------------- Loading
services/surfaceflinger/Layer.h +1 −0 Original line number Diff line number Diff line Loading @@ -89,6 +89,7 @@ private: void onFrameQueued(); virtual sp<ISurface> createSurface(); uint32_t getEffectiveUsage(uint32_t usage) const; uint32_t getTransformHint() const; bool isCropped() const; static bool getOpacityForFormat(uint32_t format); Loading
services/surfaceflinger/SurfaceFlinger.cpp +7 −0 Original line number Diff line number Diff line Loading @@ -93,6 +93,7 @@ SurfaceFlinger::SurfaceFlinger() mDebugBackground(0), mDebugDDMS(0), mDebugDisableHWC(0), mDebugDisableTransformHint(0), mDebugInSwapBuffers(0), mLastSwapBufferTime(0), mDebugInTransaction(0), Loading Loading @@ -1689,6 +1690,12 @@ status_t SurfaceFlinger::onTransact( invalidateHwcGeometry(); repaintEverything(); return NO_ERROR; case 1009: // toggle use of transform hint n = data.readInt32(); mDebugDisableTransformHint = n ? 1 : 0; invalidateHwcGeometry(); repaintEverything(); return NO_ERROR; case 1010: // interrogate. reply->writeInt32(0); reply->writeInt32(0); Loading
services/surfaceflinger/SurfaceFlinger.h +1 −0 Original line number Diff line number Diff line Loading @@ -374,6 +374,7 @@ private: int mDebugBackground; int mDebugDDMS; int mDebugDisableHWC; int mDebugDisableTransformHint; volatile nsecs_t mDebugInSwapBuffers; nsecs_t mLastSwapBufferTime; volatile nsecs_t mDebugInTransaction; Loading