summaryrefslogtreecommitdiffstats
path: root/services
Commit message (Collapse)AuthorAgeFilesLines
...
* | SurfaceTexture: default to doing GL syncJamie Gennis2012-09-181-1/+1
|/ | | | | | | | | This change makes updateTexImage default to performing the necessary synchronization and adds an argument for SurfaceFlinger to disable that synchronization so that it can be performed lazily. Change-Id: I7c20923cc786634126fbf7021c9d2541aa77be5d Bug: 6991805
* Plumb display name into SurfaceFlingerAndy McFadden2012-09-184-6/+31
| | | | | | | | | | The Surface createDisplay() call takes a display name for debugging. This change carries it through SurfaceFlinger and displays it in the "dumpsys SurfaceFlinger" output. Bug 7058158 Change-Id: I79f3474a8656ff1beb7b478e0dbf2c5de666118a
* fix external displaysMathias Agopian2012-09-181-7/+14
| | | | | | | | we were not calling eglSwapBuffers() on external displays because they can't use HWC which caused us to think they didn't have GLES composition. Change-Id: I6cef4ae40b138412d2e6f2acda33c9d222b03a83
* add support hwc 1.1Mathias Agopian2012-09-1711-89/+283
| | | | | | Bug: 7124069 Change-Id: I53d705105c4ad8954d3f50ee4f4c8b7ec936b871
* refactor things a bitMathias Agopian2012-09-174-62/+125
| | | | | | | | - decouple GL and main display initialization - ensure that each "supported" display has its own FramebufferSurface - onScreenAcquired/Released now takes a display Change-Id: If34a05f3dea40f6c79db77f4dde283a2580daac4
* Fix transform hintsAndy McFadden2012-09-164-13/+32
| | | | | | | | | The hints were being set a little too late, so the pre-rotation stuff wasn't quite working. Bug 7054997 Change-Id: Id8d5c626db7a76f768ba762a145b315878ee08e6
* Fix display projections when translated.Jeff Brown2012-09-132-11/+14
| | | | | | | | | There are two different translations to apply in the logical orientation, one before scaling and one after. So translate, scale, translate then rotate. Bug: 7139798 Change-Id: I0726991cadb62988390e77503dbbaed54f07bfe3
* Minor tweaksAndy McFadden2012-09-133-8/+2
| | | | | | | A couple of minor cleanups I stumbled over while looking at other things. Change-Id: I385ecfe1afefd577afbc59d7ef1d98d868073651
* Merge "Initialize new HWC 1.2 fields" into jb-mr1-devJesse Hall2012-09-123-24/+34
|\
| * Initialize new HWC 1.2 fieldsJesse Hall2012-09-123-24/+34
| | | | | | | | | | | | Also rename resolution* to width/height. Change-Id: Ia5f0c50d3f0a349160f314a3257c3b985e13ef1d
* | Merge "Fix display projection transforms" into jb-mr1-devJesse Hall2012-09-121-5/+8
|\ \
| * | Fix display projection transformsJesse Hall2012-09-121-5/+8
| | | | | | | | | | | | | | | Bug: 7139798 Change-Id: I61aafe99180d85563c6880d16bc367fce80e6022
* | | don't call hwc with non-empty layer lists for blanked displaysMathias Agopian2012-09-122-17/+20
| |/ |/| | | | | | | | | | | | | | | | | | | | | we now make sure to take the blanked state of a display into account when we build its list of visible layers, this ensures that we won't call prepare/set with a non-empty list when the display is blanked. Possibly fixes 7075380, 7103553, 7130187, 7016215 Bug: 7075380 Change-Id: I9fdd2e73d1b7621eaeca3d4ac2ae60d9fb1b3631
* | Merge "Fix emulator" into jb-mr1-devAndy McFadden2012-09-121-3/+6
|\ \
| * | Fix emulatorAndy McFadden2012-09-121-3/+6
| | | | | | | | | | | | | | | | | | Emulator has no HWC. Change-Id: I7810b27034f6772823142e5bf877681db1c8ee49
* | | Merge "fix typo in LayerBase::dump()" into jb-mr1-devMathias Agopian2012-09-111-1/+1
|\ \ \ | |/ / |/| |
| * | fix typo in LayerBase::dump()Mathias Agopian2012-09-111-1/+1
| | | | | | | | | | | | Change-Id: Ie4861a58baed003b7ef643931d41f6be3fbfd00c
* | | Reduce failure uncertaintyAndy McFadden2012-09-112-0/+13
|/ / | | | | | | | | | | | | | | | | This adds a trivial workaround for a one-shot boot time crash, plus an explicit check and abort for a failure condition that currently presents as a less obvious failure. Bug: 7145521, 7147557 Change-Id: I548f6a9caa9f0bd5710aaecea0e1c6c7c8f2f281
* | Reshuffle FramebufferSurfaceAndy McFadden2012-09-116-158/+202
|/ | | | | | | | | | FramebufferSurface no longer speaks directly to the FB HAL. Now everything goes through HWComposer (which may or may not be connected to a hardware composer). Added display index arg to some query methods. Change-Id: Id3e157d2d4e3555d33afbb703e518b6e92e2d6d5
* SurfaceTexture: use eglWaitSyncJamie Gennis2012-09-101-5/+3
| | | | | | | | | | | This change adds a compile-option to use eglWaitSyncANDROID to ensure that texturing operations that access the current buffer of a SurfaceTexture do not occur until the buffer is completely written. It also moves this synchronization into a new SurfaceTexture method called doGLFenceWait and changes SurfaceFlinger's Layer class to use that method rather than performing its own wait on the fence. Change-Id: I70afa88086ca7ff49a80e3cd03d423767db7cb88
* Ensure that viewport and frame are initialized.Jeff Brown2012-09-092-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | onInitializeDisplays() was posting a transaction with changes to the display projection. Unfortunately, it only set the display orientation field and left viewport and frame uninitialized. The uninitialized values flowed downstream and found themselves baked into a bogus DisplayDevice mGlobalTransform. That transform was then applied to some Rects which were turned into Regions that were them combined with other Regions. Under certain situations, the uninitialized data might have a largish value, resulting in the creation of Regions with components in excess of the Region max-value limit of 0x7ffffff (note that this is not INT_MAX). Later when performing a binary operation using the Region, the Spanner would loop indefinitely trying to figure out how to stuff a humongous region inside of a max-value region. Not content to try just once, the Spanner would continue trying again and again, pegging the CPU and hanging surface flinger during boot. Insanity soon followed. Bug: 7130713 Change-Id: I0016f0c9662185be833474c212a1dd408096ae23
* Fix display projection.Jeff Brown2012-09-071-3/+3
| | | | Change-Id: I0f253dc3759b99e05ff8344b0f513d8c289702e7
* libgui: move fence handling into ConsumerBaseJamie Gennis2012-09-061-1/+1
| | | | | | | | This change moves some common fence handling code into the base class for BufferQueue consumer classes. It also makes the ConsumerBase class initialize a buffer slot's fence with the acquire fence every time a buffer is acquired. Change-Id: I0bd88bc269e919653b659bfb3ebfb04dd61692a0
* fix a problem where all hwc layers would have the SKIP flags setMathias Agopian2012-09-052-1/+1
| | | | | | | | | the problem was that LayerBase::setPerFrameData() was always setting this flag. in fact there was no reason to do this at that point since the layer is initialized to a default state in setGeometry(). Bug: 7111259 Change-Id: Ib37b0dd7391a6163070e9aca025512159c1705f9
* Merge "Always reset layer acquireFenceFd after commit" into jb-mr1-devJesse Hall2012-09-051-0/+2
|\
| * Always reset layer acquireFenceFd after commitJesse Hall2012-09-051-0/+2
| | | | | | | | | | | | | | | | | | | | If SurfaceFlinger needs to refresh the screen but the dirty region is empty, it won't set the layer acquire fences, and stale file descriptors will be passed to HWC commit(). Now we make sure to clear the stale file descriptors for each layer right after commit(). Bug: 7078301 Change-Id: I6953ff91fc5488f105b30b07306f9c45a4c3f780
* | minor cleanupMathias Agopian2012-09-041-5/+5
| | | | | | | | Change-Id: Ied80e14878e92a506930f7a5a55adde8f260ec70
* | Merge "display projection API now has a single function instead of 3" into ↵Mathias Agopian2012-09-043-36/+16
|\ \ | | | | | | | | | jb-mr1-dev
| * | display projection API now has a single function instead of 3Mathias Agopian2012-09-043-36/+16
| | | | | | | | | | | | Change-Id: I9bf46d372b77d547486d4bbe6f1953ec8c65e98f
* | | the visibleRegion was never set in hwcomposerMathias Agopian2012-09-041-2/+2
|/ / | | | | | | | | Bug: 7089478 Change-Id: I13b031b23ce908d33f431a04e1cf87831b551260
* | implement display viewport and frameMathias Agopian2012-09-044-47/+125
| | | | | | | | | | | | note: viewport clipping is not implemented yet Change-Id: I7fde7c4de075d409d95c48bb20ba8ee017f6f00a
* | Merge "Add timeout when waiting for HW vsync" into jb-mr1-devAndy McFadden2012-09-041-9/+34
|\ \ | |/ |/|
| * Add timeout when waiting for HW vsyncAndy McFadden2012-08-311-9/+34
| | | | | | | | | | | | | | This way we don't get stuck if, say, the driver decides not to send us vsync events. Change-Id: I4af6358b3a1f304eaae5fd926ed3403fa1091827
* | add libsurfaceflinger_ddmconnection for PDK buildKeun young Park2012-08-315-2/+47
| | | | | | | | | | | | | | | | - the library is dlopened from libsurfaceflinger - the library built only when libnativehelper exists Bug: 7089510 Change-Id: Ib3ea1029d7e8f6e055f4b759d0bf68f5123fa8a1
* | the visible region sent to HWC was garbageMathias Agopian2012-08-315-5/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | we used to have a visibleRegion object per layer, but now it's per screen; so at somepoint the code got changed to calculate the per-screen visible region on the stack and that's what got passed to HWC. we're now setting the visibleRegionScreen at each frame and freeing at after the HWC set() call. We use the underlaying SharedBuffer so that in most cases we don't have to allocate, free or copy memory around. Bug: 7089478 Change-Id: I24fa556c76613a225d9fe7a6c6b727bb476144d8
* | If there is no hwc, call eglSwapBuffers for the main displayJesse Hall2012-08-311-2/+3
| | | | | | | | | | Bug: 7068568 Change-Id: I6a0309613fe3619d065b9047af6c3fb32b510d97
* | Merge "HWC 1.1: hook up hotplug event, use new display config queries" into ↵Jesse Hall2012-08-312-16/+110
|\ \ | |/ |/| | | jb-mr1-dev
| * HWC 1.1: hook up hotplug event, use new display config queriesJesse Hall2012-08-312-16/+110
| | | | | | | | Change-Id: I2fd359e5fc7e1948072c6bc6b6fe47ea5e8025c1
* | BufferQueue: use max acquired buffer countJamie Gennis2012-08-301-2/+1
| | | | | | | | | | | | | | | | | | This change makes BufferQueue derive the min undequeued buffer count from a max acquired buffer count that is set by the consumer. This value may be set at any time that a producer is not connected to the BufferQueue rather than at BufferQueue construction time. Change-Id: Icf9f1d91ec612a079968ba0a4621deffe48f4e22
* | Merge "BufferQueue: clean up buffer counting" into jb-mr1-devJamie Gennis2012-08-302-3/+3
|\ \
| * | BufferQueue: clean up buffer countingJamie Gennis2012-08-292-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | This change is a clean up of some of the handling of the maximum number of buffers that are allowed at once. It mostly renames a few member variables and methods, but it includes a couple small refactorings. Change-Id: I9959310f563d09583548d4291e1050a7bbc7d87d
* | | Merge "Handle new device api version encoding" into jb-mr1-devJesse Hall2012-08-301-9/+39
|\ \ \ | | |/ | |/|
| * | Handle new device api version encodingJesse Hall2012-08-291-9/+39
| |/ | | | | | | Change-Id: I3d36058bd5d31c23b3cc4a7eb5aa033b6f3c1955
* | fix a crasher when setting a display to a null surfaceMathias Agopian2012-08-291-27/+32
| | | | | | | | | | Bug: 7076303 Change-Id: I843dd4ee4a603b8ad51bc1ad14e429db15050bec
* | we were sometimes not setting fences properlyMathias Agopian2012-08-291-26/+36
|/ | | | | | | | | this would happen when the composition was handled entirely in h/w composer, in this case, we would not set the fences for any involved layers. Bug: 7049373 Change-Id: I1439dc156ce23c24041cdfbbebfe8ff4fdf790f8
* the layer list per display could contain non-visible layersMathias Agopian2012-08-281-7/+12
| | | | | | | | this happened because we didn't check that the visible region was within the bounds of the display. Bug: 7064121 Change-Id: I2e81850a3dc3d1474253520ad7f9e559c26d5a96
* we were not always clearing the screen properlyMathias Agopian2012-08-272-13/+13
| | | | Change-Id: I269dd866e965aebd9b3c4667095818202982f4a3
* Eradicate DisplayID.Mathias Agopian2012-08-2715-149/+125
| | | | | | | | DisplayDevices are now keyed of the wp<IBinder> the client uses. DisplayID has now become DisplayType which is just used to identify physical displays (as opposed to virtual displays such as wifi displays). Change-Id: I0c5968f2c902dcd699a7e0afacf833ff070c12ea
* Banish DisplayID from the SurfaceFlinger API.Jeff Brown2012-08-278-37/+42
| | | | | | | | | | | | | | | Use only display tokens in the API to refer to new displays. Don't require the caller to specify the display when creating a surface (since in general a surface could be shown on any display). This is intended to be a minimum change just to update the API. Note that SurfaceFlinger still uses DisplayID in a few places internally that might cause some features not to work properly when there are multiple displays (LayerScreenshot, for example). Change-Id: I3d91eec2da406eefd97bcd53655d403ad865a7e6
* Added display initialization methodAndy McFadden2012-08-243-12/+43
| | | | | | | | | | The primary display device was being configured to "blank" by default, which prevented the boot animation from appearing (unless you got lucky with the hardware composer state). Bug 6975688 Change-Id: I0fa52e9e719c6e997c5725a7baf15d9718461b78