summaryrefslogtreecommitdiffstats
path: root/services
Commit message (Collapse)AuthorAgeFilesLines
...
* get rid of ISurfaceMathias Agopian2013-03-128-175/+147
| | | | | | | | | | | | ISurface was only used to get the IGraphicBufferProducer from a Layer. It's now replaced by a BBinder subclass / IBinder and is only used as a handle to the surface, to both refer to it and manage its life-time. Also cleaned-up a bit the ISurfaceComposer interface and "create layer" code path. Change-Id: I68d0e02d57b862cffb31d5168c3bc10cea0906eb
* Fix missing recents screenshotsMathias Agopian2013-03-111-6/+8
| | | | | | | | | | | | We were using the "visible layer list" when taking screenshots, which doesn't work when a layer is behind other opaque layers and therefore hidden. We fix this by using the full layer list, filtered by the layerstack of the display we're looking at. Bug: 7552304 Change-Id: I4b6f77e5511aea94f8d218975b6e22738e7e5d5b
* make sure to call compositionComplete after taking a screenshotMathias Agopian2013-03-081-0/+3
| | | | | | | | older drivers which are doing implicit synchronization need this or they could deadlock. Bug: 8341885 Change-Id: Icd980a6be16071678d6151e34725b3c1c547d7ee
* workaround to fix screenshot leak on N4Mathias Agopian2013-03-061-0/+3
| | | | | | Bug: 8322020 Change-Id: Ie60af0eb431866b8d64b2674ae7bd8b5ee05f5d6
* Merge changes I66511c08,Ia051949f,Ic7451365,I5b571a4c into jb-mr2-devMathias Agopian2013-03-0717-1412/+976
|\ | | | | | | | | | | | | | | * changes: Get rid of LayerBase. Make LayerDim a regular Layer instead of a LayerBase fold LayerBaseClient into LayerBase Remove support for ScreenshotLayer
| * Get rid of LayerBase.Mathias Agopian2013-03-0514-1238/+943
| | | | | | | | | | | | | | | | The functionality of LayerBase and Layer is folded into Layer. There wasn't a need for this abstraction anymore. Change-Id: I66511c08cc3d89009ba4deabf47e26cd4cfeaefb
| * Make LayerDim a regular Layer instead of a LayerBaseMathias Agopian2013-03-053-4/+27
| | | | | | | | | | | | this is in preparation to get rid of LayerBase entirely Change-Id: Ia051949fc5205fd87371331145356ee11598a597
| * fold LayerBaseClient into LayerBaseMathias Agopian2013-03-0510-159/+104
| | | | | | | | Change-Id: Ic745136522df59c42f0885fd969e75ea55d09f01
| * Remove support for ScreenshotLayerMathias Agopian2013-03-056-110/+1
| | | | | | | | Change-Id: I5b571a4cf3faa77d2c4aca916fa4bd00a1065bb9
* | Return NO_MEMORY when glReadPixels() fails.Jeff Sharkey2013-03-051-0/+2
|/ | | | Change-Id: Ic66134ef457e8442ae9135e9ec50e3d02932a253
* Merge "rework screenshot API and implementation" into jb-mr2-devMathias Agopian2013-03-055-326/+210
|\
| * rework screenshot API and implementationMathias Agopian2013-03-015-326/+210
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - SurfaceFlinger now supports to take a screenshot directly into an IGraphicBufferProducer - reimplement the IMemoryHeap screenshot on top of the above - reimplement LayerScreenshot such that its BufferQueue is directly used as the destination of the screenshot. LayerScreenshot is now a thin wrapper around Layer Bug: 6940974 Change-Id: I69a2096b44b91acbb99eba16f83a9c78d94e0d10
* | Merge "Init displays to null layer stack" into jb-mr2-devJesse Hall2013-03-053-8/+14
|\ \
| * | Init displays to null layer stackJesse Hall2013-02-283-8/+14
| |/ | | | | | | | | | | | | | | | | | | | | | | When a display is added, initialize it to use an empty layer stack, so if it is somehow visible it will show black. It will be assigned the real layer stack -- along with a projection and other properties -- by window manager soon. Normally a display remains blanked until window manager has decided what to show on it, but for HDMI connected at boot that isn't currently the case. Bug: 7258935 Change-Id: Ic9bb25f7a9b8d9d3772b097ab1d6fa03bc8780a1
* | implement display projection clipping in h/w composerMathias Agopian2013-02-283-5/+80
| | | | | | | | | | | | | | | | | | - cropping to the projection's "viewport" is "simply" accomplished by intersecting it with the window crop expressed in layerstack space. Bug: 7149437 Change-Id: I0e90b3f37945292314b5d78a8f134935967e8053
* | refactor the crop region for hwc is calculated/setMathias Agopian2013-02-284-42/+90
| | | | | | | | | | | | | | | | | | - the crop region is now always calculated and set in LayerBase::setGeometry which uses new virtuals to access the "content" crop and transform (which are provided by the Layer subclass) Change-Id: Ib7769bdec0917dd248f926600c14ddf9ea84897a
* | apply the projection's viewport to the visibleregion passed to hwcMathias Agopian2013-02-283-68/+68
| | | | | | | | | | | | | | | | | | | | | | each desplay's projection's viewport essentially clips each layer, so this should be reflected in the visibleregion passed to h/w composer. DisplayDevice getViewport and getFrame are now guaranteed to return valid Rects. Change-Id: I4c25f34fb26af10179eb26d429ca6c384c671e91
* | set correct crop rectangle in LayerBase::setCropMathias Agopian2013-02-282-8/+11
|/ | | | | | | | | | | | | | The crop always had left=top=0, because the crop position and the layer's transform were merged together in computeBounds() (which really used to compute the bounds in screen space, which we usually call the "frame" elsewhere in the code) Note: in practice this crop value is not used by hwc, because it's overridden in Layer::setGeometry(), which is why this bug was never apparent. Change-Id: I1ec6400a8fc8314408e4252708f43ea98c2fe64e
* Initialize DisplayData fences to NO_FENCE, not NULLJesse Hall2013-02-273-8/+19
| | | | | | | | | Also fix another place that was checking for NULL fence rather than Fence::isValid(). Bug 8283950 Change-Id: Ie06db327eb416828d8dac139171d96d4470b2e35
* SurfaceFlinger: fix a couple NULL fence checksJamie Gennis2013-02-251-2/+2
| | | | | | | This change replaces checks for a NULL fence pointer with calls to Fence::isValid. There should no longer be NULL fences. Change-Id: If17c9c132fcb1801531bf7588f8ba53476c57dad
* Refactoring: Rename SurfaceTextureClient to SurfaceMathias Agopian2013-02-147-24/+25
| | | | Change-Id: Ibed34175ae273608393aaa5f0a7df207dc40d709
* get rid of Surface identity and tokenMathias Agopian2013-02-136-52/+29
| | | | | | we use the IBinder instead. Change-Id: I4aa0b58869ba43f19980013620051e5a261b062d
* libgui: disallow NULL Fence pointersJamie Gennis2013-02-123-6/+5
| | | | | | | | | This change eliminates the uses of a NULL sp<Fence> indicating that no waiting is required. Instead we use a non-NULL but invalid Fence object for which the wait methods will return immediately. Bug: 7892871 Change-Id: I5360aebe3090422ef6920d56c99fc4eedc642e48
* Merge changes I8bded1ea,I7478293eJamie Gennis2013-02-116-24/+63
|\ | | | | | | | | | | * changes: SurfaceFlinger: add win anim frame time tracking SurfaceFlinger: remove a driver bug workaround
| * SurfaceFlinger: add win anim frame time trackingJamie Gennis2013-02-086-21/+63
| | | | | | | | | | | | | | | | This change makes the 'dumpsys SurfaceFlinger --latency' command with no extra args dump the frame timestamp data for the most recent frames that SurfaceFlinger generated that included window animation transaction changes. Change-Id: I8bded1ea08a4cddefef0aa955401052bb9107c90
| * SurfaceFlinger: remove a driver bug workaroundJamie Gennis2013-02-041-3/+0
| | | | | | | | Change-Id: I7478293e87899d6e467db8c2f9e295935c8b1d4e
* | only disable hwc when alpha < 1.0Mathias Agopian2013-02-071-1/+3
| | | | | | | | | | Bug: 8149181 Change-Id: Ib3c7a44f04871e020adceeae16d002141ac758d4
* | Add support for plane-alpha in HWCMathias Agopian2013-02-054-20/+31
| | | | | | | | Change-Id: I218e7dd5f23de535aabce61e993002ab6cb46cdd
* | Merge "Remove unused HWCLayer::setPerFrameDefaultState()"Jesse Hall2013-02-053-5/+0
|\ \ | |/ |/|
| * Remove unused HWCLayer::setPerFrameDefaultState()Jesse Hall2013-01-143-5/+0
| | | | | | | | | | Bug: 7977590 Change-Id: Ic49c4e38ef2ee6beaeb268c406347c882135bdf0
* | am fc866eb8: am 845ed8fd: Merge "DisplayDevice: initialize mDisplayToken ↵Jesse Hall2013-01-141-0/+1
|\ \ | |/ |/| | | | | | | | | correctly" * commit 'fc866eb8423cd1d720683946f7d102547718b6c9': DisplayDevice: initialize mDisplayToken correctly
| * am 845ed8fd: Merge "DisplayDevice: initialize mDisplayToken correctly"Jesse Hall2013-01-141-0/+1
| |\ | | | | | | | | | | | | * commit '845ed8fdaa34d0f684c93bf4dbadb9162f769235': DisplayDevice: initialize mDisplayToken correctly
| | * Merge "DisplayDevice: initialize mDisplayToken correctly"Jesse Hall2013-01-141-0/+1
| | |\
| | | * DisplayDevice: initialize mDisplayToken correctlyChih-Wei Huang2013-01-071-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | mDisplayToken should be initialized by displayToken. Change-Id: I0a5fec1f1732200a32d10b1575239dceffe6dee4
* | | | am f3e9d5bd: am cbe51356: Merge "Remove support for legacy HWC version encoding"Jesse Hall2013-01-141-11/+1
|\ \ \ \ | |/ / / | | | | | | | | | | | | * commit 'f3e9d5bde57a41593a7dbc15e6f1fdb1ea64ea74': Remove support for legacy HWC version encoding
| * | | am cbe51356: Merge "Remove support for legacy HWC version encoding"Jesse Hall2013-01-141-11/+1
| |\ \ \ | | |/ / | | | | | | | | | | | | * commit 'cbe5135610cd3c919e6334fada72cc52238bb8b0': Remove support for legacy HWC version encoding
| | * | Remove support for legacy HWC version encodingJesse Hall2013-01-101-11/+1
| | |/ | | | | | | | | | Change-Id: If03ae1ebf10d15777310e1449a57473021390582
* | | Merge "Add some comments."Andy McFadden2013-01-116-9/+75
|\ \ \
| * | | Add some comments.Andy McFadden2013-01-116-9/+75
| | | | | | | | | | | | | | | | | | | | | | | | Also, minor tweak to SurfaceTextureLayer. Change-Id: If616d5ee4e8226dd0e16c5dbb0e0f80db553110e
* | | | Reduce C++11 warningsAndy McFadden2013-01-112-9/+9
|/ / / | | | | | | | | | | | | | | | A few typecasts to fix "narrowing conversion" complaints. Change-Id: Ib2118079a2ca33959c748d03d8c6f1722d62e8fe
* | | workaround: don't reset compositionType to HWC_FRAMEBUFFERMathias Agopian2013-01-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This workaround a HWC HAL issue in Nexus 7, which causes videos and live wallpapers to animate slowly. Bug: 7563862 Change-Id: I87803aaad9751b1fd8392b9732304d4bccec659a
* | | Rename ISurfaceTexture and SurfaceTextureAndy McFadden2012-12-189-22/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The C++ class names don't match what the classes do, so rename ISurfaceTexture to IGraphicBufferProducer, and SurfaceTexture to GLConsumer. Bug 7736700 Change-Id: Ia03e468888025b5cae3c0ee1995434515dbea387
* | | Merge "SurfaceFlinger: Move GraphicBufferAlloc to libgui"Jamie Gennis2012-12-125-100/+2
|\ \ \
| * | | SurfaceFlinger: Move GraphicBufferAlloc to libguiJamie Gennis2012-12-115-100/+2
| | | | | | | | | | | | | | | | | | | | | | | | This change moves the GraphicBufferAlloc class from SurfaceFlinger to libgui. Change-Id: Idf31d2004efa2651b60590733f73c4a7b831e8a9
* | | | Avoid unnecessary texture bindAndy McFadden2012-12-113-17/+23
|/ / / | | | | | | | | | | | | | | | | | | In SurfaceFlingerConsumer, check to see if native fence sync is enabled. If so, defer the texture binding step to Layer::onDraw. Change-Id: I7d4034a31c0143207eea2509dfa13ef3820f9b8c
* | | Refactor SurfaceTexture a bit.Andy McFadden2012-12-115-42/+196
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rearranges updateTexImage() so that the SurfaceFlinger-specific behavior is in a new SurfaceFlingerConsumer subclass. SurfaceTexture behavior should not be altered. Instead of acquire-bind-release we now do acquire-release-bind, but since it's all done with the lock held there shouldn't be any externally-visible change. Change-Id: Ia566e4727945e2cfb9359fc6d2a8f8af64d7b7b7
* | | SurfaceFlinger: work around a driver bugJamie Gennis2012-12-071-0/+6
| | | | | | | | | | | | Change-Id: I4490f308b12e9b6fda2ea7255eb19d867d6d008c
* | | am a7da0dda: am 98cbec81: am efd614b8: Merge "make transform hint ↵Mathias Agopian2012-11-274-23/+64
|\ \ \ | |/ / | | | | | | | | | | | | | | | multi-display aware" into jb-mr1.1-dev * commit 'a7da0dda39cf1e807eea1304b48d4583e7329b72': make transform hint multi-display aware
| * | am 98cbec81: am efd614b8: Merge "make transform hint multi-display aware" ↵Mathias Agopian2012-11-274-23/+64
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | into jb-mr1.1-dev * commit '98cbec81be1d39223e33abde9ac35e43b62918bf': make transform hint multi-display aware
| | * | make transform hint multi-display awareMathias Agopian2012-11-214-23/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if a layer is not mirrored, we now use its display as the source for the transfrom hint calculation instead of always using the default (main) display. this change does two thing: 1) we make updateTransformHint take a DisplayDevice as a parameter instead of hard-coding the main display. 2) each time we do a transaction that could change the hint, we go through all layers and figure out which display should be used for their transform hint. Bug: 7599344 Change-Id: I9b04a95e6c372dd770bacf81d8ef6f8e31b87b83