summaryrefslogtreecommitdiffstats
path: root/services
Commit message (Collapse)AuthorAgeFilesLines
* don't reallocate the mesh each time we use itMathias Agopian2013-08-137-55/+87
| | | | | | | | the Mesh object can be part of each Layer (at least currently). also reworked the Mesh code a bit to make it easier to access the vertex data. Change-Id: I0490851ba898f0aa2e55b62958dcd8bdb535e98b
* SurfaceFlinger now uses GLES 2.x when availableMathias Agopian2013-08-1323-224/+1436
| | | | | | Bug: 8679321 Change-Id: I2b152d01fb4e2de2ea9fe87f1ddbd6826d7520d7
* allow "system" screenshots even when the secure flag is setMathias Agopian2013-08-131-6/+12
| | | | | | | | | | we need too allow this case so that things like the rotation animation can work. with this change we only permit these screenshot if the destination is SurfaceFlinger itself. Bug: 10235036 Change-Id: I66fea5391e52b0d7f17f25827572b236f2d9eb71
* make sure we have a context when creating the 1st surfaceMathias Agopian2013-08-081-0/+4
| | | | | | | also add an option to dump the stack trace when calling a GL function without a context. Change-Id: I57b72bb8c322ac4253c3077bf150621bd9863b69
* Add ISurfaceComposer::destroyDisplayJesse Hall2013-08-082-0/+20
| | | | | Bug: 10191053 Change-Id: Ia89286f95421344a60ffedaaca5825c4e3cd7f9e
* batteryservice: add battery current now and charge counter dataTodd Poynor2013-08-071-0/+4
| | | | Change-Id: I4b3ea25342d4a03a8e38bfee2ef3b1ce54f82582
* Merge "Set the swap interval of virtual display surfaces to 0"Jesse Hall2013-08-072-2/+12
|\
| * Set the swap interval of virtual display surfaces to 0Jesse Hall2013-08-062-2/+12
| | | | | | | | | | | | | | | | | | This prevents slow/malicious virtual display consumers from backpressuring SurfaceFlinger and preventing it from updating other displays. Bug: 10193714 Change-Id: I3e877d97202628d2d9abea24b66576f38299c14d
* | remove support for glReadPixels screenshot pathMathias Agopian2013-08-062-57/+21
| | | | | | | | | | | | | | this was only needed on some chipset we're not supporting in KLP. Change-Id: I2e8fc07f135030bd61d2e241a8e426f1a4316425
* | All consumers now take an IGraphicBufferConsumer instead of a BufferQueueMathias Agopian2013-08-0611-50/+53
|/ | | | | | | | | | this means they only have access to the consumer end of the interface. we had a lot of code that assumed consumers where holding a BufferQueue (i.e.: both ends), so most of this change is untangling in fix that Bug: 9265647 Change-Id: Ic2e2596ee14c7535f51bf26d9a897a0fc036d22c
* Binderize the consumer side of BufferQueueMathias Agopian2013-08-011-1/+2
| | | | | | | | | | While currently untested, this should allow to move the BuffereQueue in the consumer process and have everything work as usual. Bug: 9265647 Change-Id: I9ca8f099f7c65b9a27b7e7a3643b46d1b58eacfc
* SurfaceFlinger: Set the result of binderized screencaptureMike J. Chen2013-07-301-0/+1
| | | | | | | | | | | | | | | | | A recent change to screencapture to have the call to IGraphicBufferProducer happen on the incoming binder thread didn't set the result so the result was always returned as NO_ERROR. This made screencap fail on some devices (e.g. Wolfie) which relies on some kind of fallback mechanism to generate the screencap but the fallback mechanism doesn't get triggered because the error isn't returned. Bug: 9989385 Change-Id: I2aee91ea1034869fcbb0f49b9a0087c3cff43bbe Signed-off-by: Mike J. Chen <mjchen@google.com>
* single buffer mode for BufferQueueMathias Agopian2013-07-262-2/+2
| | | | | Bug: 9891035 Change-Id: Id1ab5f911a6dc4c1d8235e65775b3d3635231ad4
* get rid of HAL pixelformats 5551 and 4444Mathias Agopian2013-07-261-2/+0
| | | | Change-Id: I39409103144c1ba09078c4ddc323a58987fb09ea
* make transparent pixels transparents againMathias Agopian2013-07-261-2/+2
| | | | | | apparently boolean logic in hard... Change-Id: Ie70401fe12e0fa00b0b8c7cc475c1438cdbbf531
* get rid of PixelFormatInfo and simplify thingsMathias Agopian2013-07-252-15/+10
| | | | Change-Id: I025a362cc12d5b9b794fac14be500e25aab65396
* add libbatteryserviceTodd Poynor2013-07-254-0/+201
| | | | | | | | | | | | | IBatteryPropertiesListener is used by clients such as BatteryService to receive notifications of changed battery/power status (from healthd). IBatteryPropertiesRegistrar manages registrations of IBatteryPropertiesListener clients. Add BatteryService native header with defines from BatteryManager, and class BatteryProperties to pass battery/power status around. Change-Id: I44e2736e503b586794097b7b9d31d07fefd9b15a
* Merge "surfaceflinger: add frame duration logging"Jamie Gennis2013-07-249-12/+176
|\
| * surfaceflinger: add frame duration loggingJamie Gennis2013-07-239-12/+176
| | | | | | | | Change-Id: Ib414a45e7e191f23a2726cbbbeb606e9ce68a3b5
* | Merge "Add C++ library for ConnectivityManager"Geremy Condra2013-07-233-0/+106
|\ \
| * | Add C++ library for ConnectivityManagerChad Brubaker2013-07-163-0/+106
| | | | | | | | | | | | | | | | | | Add C++ library for access to ConnectivityManager's markSocketAsUser. Change-Id: Icb9faa5be8c11d10e5c4a3bf95d338319449399c
* | | move services executables sources in their respective src folderMathias Agopian2013-07-226-0/+128
| |/ |/| | | | | Change-Id: Ic65434a26c7fed1699abf0851fec6faa40e09c0c
* | Make ANW.setSwapInterval(0) work againMathias Agopian2013-07-192-9/+10
| | | | | | | | | | | | | | | | | | | | | | we can now queue/dequeue a buffer in asynchrnous mode by using the async parameter to these calls. async mode is only specified with those calls (it is not modal anymore). as a consequence it can only be specified when the buffer count is not overidden, as error is returned otherwise. Change-Id: Ic63f4f96f671cb9d65c4cecbcc192615e09a8b6b
* | BufferQueue improvements and APIs changesMathias Agopian2013-07-187-45/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this is the first step of a series of improvements to BufferQueue. A few things happen in this change: - setSynchronousMode() goes away as well as the SynchronousModeAllowed flag - BufferQueue now defaults to (what used to be) synchronous mode - a new "controlled by app" flag is passed when creating consumers and producers those flags are used to put the BufferQueue in a mode where it will never block if both flags are set. This is achieved by: - returning an error from dequeueBuffer() if it would block - making sure a buffer is always available by replacing the previous buffer with the new one in queueBuffer() (note: this is similar to what asynchrnous mode used to be) Note: in this change EGL's swap-interval 0 is broken; this will be fixed in another change. Change-Id: I691f9507d6e2e158287e3039f2a79a4d4434211d
* | Fix build -- update for function signature changeJesse Hall2013-07-161-1/+1
| | | | | | | | Change-Id: I9c2448d5853c69ec7e962847fdaba9a99906cc42
* | Merge "Rewrite VirtualDisplaySurface"Jesse Hall2013-07-169-21/+591
|\ \
| * | Rewrite VirtualDisplaySurfaceJesse Hall2013-07-159-21/+591
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous implementation assumed that the HWC could read and write the same buffer on frames that involved both GLES and HWC composition. It turns out some hardware can't do this. The new implementation maintains a scratch buffer pool to use on these mixed frames, but on GLES-only or HWC-only frames still does composition directly into the output buffer. Bug: 8384764 Change-Id: I7a3addb34fad9bfcbdabbb8b635083e10223df69
* | | Merge "always pass the BufferQueue explicitely to consumers"Mathias Agopian2013-07-162-7/+6
|\ \ \
| * | | always pass the BufferQueue explicitely to consumersMathias Agopian2013-07-122-7/+6
| | |/ | |/| | | | | | | Change-Id: I883b0a7b19d8e722f9ab714ba6f49e658b02ca86
* | | Merge "Fix issue #9860494: Waiting for service batteryinfo..."Dianne Hackborn2013-07-161-1/+1
|\ \ \
| * | | Fix issue #9860494: Waiting for service batteryinfo...Dianne Hackborn2013-07-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | I changed the name of the service, this needs to follow. Change-Id: Id8e346cee9d75cfe142cd43f6aea43302878b6dc
* | | | Add skeleton of input flinger.Jeff Brown2013-07-153-0/+178
|/ / / | | | | | | | | | Change-Id: I7f25080e446d4d3d9de9b18fe432a09bc751e0d9
* | | Merge "SurfaceFlinger: EventThread: Fix Vsync array size."Jesse Hall2013-07-121-1/+1
|\ \ \ | |/ / |/| |
| * | SurfaceFlinger: EventThread: Fix Vsync array size.Saurabh Shah2013-07-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Vsync array size is specified as HWC_DISPLAY_TYPES_SUPPORTED whose value luckily happens to be 2. That enum is actually used for querying hwc for the number of displays supported. The implementation file EventThread.cpp correctly accesses the array upto HWC_NUM_DISPLAY_TYPES Change-Id: I36e3f0913e7d6fda7bbf4449c1fb32c7f18bb934 Signed-off-by: Amara Venkata Mastan Manoj Kumar<manojavm@codeaurora.org> Signed-off-by: Saurabh Shah <saurshah@codeaurora.org>
* | | resolved conflicts for merge of 00aea5c5 to masterMathias Agopian2013-07-126-31/+38
|\ \ \ | | | | | | | | | | | | Change-Id: Ie1769be863ee2d411eae451907a928db57882e14
| * \ \ am ac9a96da: fix a dead-lock in sensorserviceMathias Agopian2013-07-126-31/+38
| |\ \ \ | | | | | | | | | | | | | | | | | | | | * commit 'ac9a96da65f6eae4513654adaad8a457d1c1575c': fix a dead-lock in sensorservice
| | * | | fix a dead-lock in sensorserviceMathias Agopian2013-07-126-31/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sensorservice would deadlock if for some reason a sensor failed to enable. simplifed the code a bit, and made it behave a little closer to mr1.1 -- I couldn't convince myself that some changes in how locks were used were correct. Bug: 9794362 Change-Id: I6110f5dbb67e543f1c71d127de2299232badb36a
| * | | | am 23dacde4: [DO NOT MERGE] fix a bug where surfaceflinger and system_server ↵Mathias Agopian2013-05-171-27/+117
| |\ \ \ \ | | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | could deadlock * commit '23dacde4b624921df4f2c9646d20ca7acae357b6': [DO NOT MERGE] fix a bug where surfaceflinger and system_server could deadlock
| | * | | [DO NOT MERGE] fix a bug where surfaceflinger and system_server could deadlockMathias Agopian2013-05-171-27/+117
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | because surfaceflinger handles screenshot in a different thread from the binder thread that requested it and because the IGraphicBufferProducer is a synchronous interface calling back into the system server; it is possible for the latter to run out of binder threads (b/c it holds a lock while calling into SF). The solution is to make sure all calls on IGraphicBufferProducer happen on the incoming binder thread. We achieve this by creating a IGBP wrapper which is given to the screenshot code. Bug: 8734824 Change-Id: Ife2441c7322e51ecfb20e0df03dacf6bce49578e
* | | | | Merge "Pay attention to buffer timestamps"Andy McFadden2013-07-114-8/+64
|\ \ \ \ \ | |_|_|/ / |/| | | |
| * | | | Pay attention to buffer timestampsAndy McFadden2013-07-104-8/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When acquiring a buffer, SurfaceFlinger now computes the expected presentation time and passes it to the BufferQueue acquireBuffer() method. If it's not yet time to display the buffer, acquireBuffer() returns PRESENT_LATER instead of a buffer. The current implementation of the expected-present-time computation uses approximations and guesswork. Bug 7900302 Change-Id: If9345611c5983a11a811935aaf27d6388a5036f1
* | | | | fix SF buffer croppingMathias Agopian2013-07-105-38/+79
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a buffer had a crop (meaning its content is scaled to the window size) and a window crop was defined, the resulting crop couldn't be expressed properly because h/w composer's API was limited to integers, since this is fixed in h/w composer 1.3, we take adventage of this to make sure we get the correct crop. this bug could result in the buffer being scaled by an incorrect ratio and be slightly offset; moreover, it would produce different results from the GL code path, which is always correct. Change-Id: I8e20e00b6e26177d14f4ab4d2cd581e26c818892
* | | | fix a bug where surfaceflinger and system_server could deadlockMathias Agopian2013-07-081-10/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | because surfaceflinger handles screenshot in a different thread from the binder thread that requested it and because the IGraphicBufferProducer is a synchronous interface calling back into the system server; it is possible for the latter to run out of binder threads (b/c it holds a lock while calling into SF). The solution is to make sure all calls on IGraphicBufferProducer happen on the incoming binder thread. We achieve this by creating a IGBP wrapper which is given to the screenshot code. Bug: 8734824 Change-Id: I2be85660d9dc65d239d68f6d3ab3c973c13b34cc
* | | | Merge "Refactor SF. Move all GL operations in their own class."Mathias Agopian2013-07-0817-476/+714
|\ \ \ \
| * | | | Refactor SF. Move all GL operations in their own class.Mathias Agopian2013-07-0317-476/+714
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this is the first step to add support for GLES 2.x, this change breaks the dependency of SF on GLES 1.x by moving all operation into their own class. Bug: 8679321 Change-Id: I0d2741eca2cefe67dfd9cf837cac10c4d126928b
* | | | improve sensorservice's dumpsysMathias Agopian2013-07-085-37/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | it now displays the reported trigger mode properly, as well as the number and type of the last received data Change-Id: I2ff64b32ab71f1332bc2e09671c8c02bb9550490
* | | | Merge "simplify some unnecessary complex code"Mathias Agopian2013-07-082-16/+4
|\ \ \ \
| * | | | simplify some unnecessary complex codeMathias Agopian2013-07-082-16/+4
| |/ / / | | | | | | | | | | | | | | | | | | | | getSensorType() ran in O(n) instead of O(1). fix that. Change-Id: Idcf29e46fc34db32604a0d8e5a9156486783b74f
* | | | Debug code for detecting all black pixels screenshotsMathias Agopian2013-07-082-0/+39
|/ / / | | | | | | | | | | | | Bug: 9120292 Change-Id: If60db32524db973bb1f905ba3cb415c2a1cd7e71
* | | SurfaceFlinger: fix releaseBuffer in updateTexImageLajos Molnar2013-06-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Allow releasing a buffer acquired in the past. Change-Id: I3f27f1caec109c1a47286fc4d2235c6e1afe9022 Signed-off-by: Lajos Molnar <lajos@google.com> Bug: 9516405