Commit Graph

186 Commits

Author SHA1 Message Date
Mathias Agopian
ebeb709596 fix debug.sf.showbackground
Change-Id: Ie4eeca006ad6d8030900d8cb0029e4d1c22474fb
2010-12-14 18:38:36 -08:00
Mathias Agopian
da9584dc29 fix [3223749] media server crashes when switching mode from video capture to still image capture
there was an issue were in some situation SF would call prepare() on hwc
with a NULL handle and never call prepare again.
in this situation, we onw set the SKIP flag to make sure that hwc
won't process this layer and as soon as we receive our first buffer we
trigger a recompute of the visible regions which will end-up calling
prepare() again.

Change-Id: I6b400b2df79712408b9315a9859290c7fcb1609e
2010-12-14 15:53:39 -08:00
Mathias Agopian
fb88981051 Merge "fix [3176642] Camera preview turns completely black for multiple toggles between camera and camcorder app" 2010-12-14 15:51:41 -08:00
Mathias Agopian
5eee3d2b13 Merge "minor clean-up. SurfaceFlinger doesn't need libpixelflinger.so." 2010-12-14 15:51:32 -08:00
Mathias Agopian
dd17b3eaa9 fix [3176642] Camera preview turns completely black for multiple toggles between camera and camcorder app
There was a leak of Surface tokens when a surface was detached from a UserClient.
We now always detach a surface from its client before attaching to the new one,
this guarantees that its token is freed.

Change-Id: Icfad0b16286ed58155bdfafdf36ab161440aa485
2010-12-13 16:49:05 -08:00
Mathias Agopian
455d18d4c2 minor clean-up. SurfaceFlinger doesn't need libpixelflinger.so.
Change-Id: I3bdca74351c8e480a05084bc412a96c5f685221d
2010-12-13 16:47:31 -08:00
Mathias Agopian
bf2c6a6c8f [3258939] Need snapshot to limit which layers are included
Change-Id: Id7351a0e3f53dde99b291cffba553d89fd4d7ca9
2010-12-10 16:22:31 -08:00
Mathias Agopian
f345069099 [3211070] camera preview image is rendered offset from the UI overlay frame
somehow this change got lost.

Change-Id: I36f6c7ef3f782918042b77e9dc91a4c811d84a40
2010-12-08 17:40:28 -08:00
Mathias Agopian
86bdb2f918 fix [3260137] Sometimes front-facing camera mirroring is wrong
make sure to take the buffer's orientation into account.

Change-Id: I9fef89e66368ad2dec1cb8c7b77ac2b3b4858efb
2010-12-08 17:23:18 -08:00
Mathias Agopian
1293a8eb56 More clean-up. Get rid off the "blur" effect in SurfaceFlinger
For multiple reason, this effect is not maintainable and was never
used due to its abysmal performance. it'll be resurected when it can be
implemented efficiently.

Change-Id: Id4222c9b86c629275cdec18873ef07be8723b6d2
2010-12-08 17:13:19 -08:00
Mathias Agopian
e0be194c7b am 74da537f: Merge "[317580] fix issue where the screen wouldn\'t be rotated properly in bypass mode" into gingerbread
* commit '74da537f80ba36c1279c04fcb85d89fc38c246a6':
  [317580] fix issue where the screen wouldn't be rotated properly in bypass mode
2010-12-08 16:15:08 -08:00
Mathias Agopian
a5529c8778 remove support for PUSH_BUFFER surfaces and overlays
the same functionality is now supported through
the h/w composer HAL, and YUV support in the GPU.

Change-Id: I8146605449954b8e8fd7f78810b7d873c2d8f5bf
2010-12-08 16:13:59 -08:00
Erik Gilling
1d21a9cafc surfaceflinger: add support for gralloc dump hooks
Change-Id: Ib6f539ed0132b70d040d653c03d52cc04249ac3c
2010-12-08 15:40:11 -08:00
Mathias Agopian
5ec99b57c3 should fix build.
Change-Id: I7705227ad123c73714af2ecb7ad84f5432a21c1d
2010-12-07 23:41:55 -08:00
Mathias Agopian
a1aa18fc26 resolved conflicts for merge of a0f011ff to master
Change-Id: I4c17021fc269ce66c98cc345353600eda332f980
2010-12-07 22:53:40 -08:00
Mathias Agopian
e24cc7a38d [317580] fix issue where the screen wouldn't be rotated properly in bypass mode
In some situations, the screen transformation would not be
applied while in bypass mode.

Change-Id: I3d6dd52e4c12b11aae97b54bf8e2322536eee37f
2010-12-07 21:16:14 -08:00
Mathias Agopian
b5a00fcb71 am 48f42f8c: am 4153bf3a: Merge "[3171580] don\'t automatically log GraphicBuffer allocation failures" into gingerbread
* commit '48f42f8c3fbd33b2f46c6290ff5963dd58938cf9':
  [3171580] don't automatically log GraphicBuffer allocation failures
2010-12-07 17:24:03 -08:00
Mathias Agopian
e4f81090c2 am a2977c38: Merge changes Ie03796ae,Ide3e980a into gingerbread
* commit 'a2977c383d363e1e88a5b36230b1fa4c312807d2':
  [3171580] SurfaceFlinger Bypass mode. (DO NOT MERGE)
  [3171580] Add transform field to native buffers. (DO NOT MERGE)
2010-12-07 14:22:56 -08:00
Mathias Agopian
9669d23cae am 05813b0e: Merge changes I244b5469,I32044e91 into gingerbread
* commit '05813b0eb92cb1bc79607ee402f14ca1e4b43f6d':
  [3253328, 3171580] Treat GONE and INVISIBLE views the same when calculating transparent regions
  [3171580] Fix two typos related to fixed-size buffers
2010-12-07 14:20:14 -08:00
Mathias Agopian
372c56e98b am 4153bf3a: Merge "[3171580] don\'t automatically log GraphicBuffer allocation failures" into gingerbread
* commit '4153bf3a259624a2f2dc497b77b225a1fb517abc':
  [3171580] don't automatically log GraphicBuffer allocation failures
2010-12-07 14:20:09 -08:00
Mathias Agopian
22c67843be [3171580] SurfaceFlinger Bypass mode. (DO NOT MERGE)
This is a poor's man precursor to the h/w composer HAL.
Basically we detect when a window is full screen and in
that case we bypass surfaceflinger's composition step, which
yields to much improved performance.

Change-Id: Ie03796ae81a1c951949b771c9323044b980cb347
2010-12-03 17:35:07 -08:00
Mathias Agopian
733189d408 [3171580] Fix two typos related to fixed-size buffers
mFixedSize was never set, this bug was introduced during some "cleanup", in
practice this could cause some issues when a fixed-size buffer was used and
the window was resized.

Layer::drawForSreenShot() had a typo that had no effect.

mFixedSize was used to determine if filtering was needed, which was a bit too
conservative and created a dependency between filtering and "fixed size" states
which should exist.

Now we enable filtering based on the size of the buffer vs. the size of the layer.

Change-Id: I32044e91b0c944c1b137efdceb3f01dfaa78119d
2010-12-03 17:35:06 -08:00
Mathias Agopian
678bdd6349 [3171580] don't automatically log GraphicBuffer allocation failures
some of these failures are not fatal and even expected in some cases
so they should not emit a dump in the log in those cases.

Change-Id: Idcfa252e3bfa9d74e27fe4ad8f8623aa01aa9c5e
2010-12-03 17:33:09 -08:00
Louis Huemiller
0404814194 Remove const_cast to layer handle
Change-Id: Ica1e089cb56b5f9f46ab87abf735ffe7237fc926
2010-12-01 12:29:36 -08:00
Jamie Gennis
4ba398df17 Merge "Implement reducing the buffer count of a Surface." 2010-11-11 15:26:21 -08:00
Jamie Gennis
54cc83e8a4 Implement reducing the buffer count of a Surface.
Change-Id: I7f979c60c06d654aa8265002836277434bc1a64f
Bug: 3095167
2010-11-11 14:06:38 -08:00
Jamie Gennis
37b126a3b2 Remove a problematic empty update optimization.
This change removes an optimization from SurfaceFlinger that skipped
composition when it got window updates that had an empty dirty region.
This optimization caused problems because it would skip the hwcomposer
set call, which could leave the window's previous frame buffer bound to
an overlay plane.  When the application subsequently dequeued and tried
to lock its next buffer (which would be the buffer currently bound to
the overlay), the lock call would block until the next hwcomposer set
call (which may never happen).

Change-Id: I563b626a1d52c1f30eb82489eae0ceb4edc79936
Bug: 3138752
2010-11-10 15:09:09 -08:00
Mathias Agopian
c23902b27f am 5c0efef9: am 7d452f69: Merge "really fix [3118445] Transform * Transform does not work as expected" into gingerbread 2010-10-27 23:48:26 -07:00
Mathias Agopian
c2dba08cc6 am 7d452f69: Merge "really fix [3118445] Transform * Transform does not work as expected" into gingerbread 2010-10-27 23:46:25 -07:00
Mathias Agopian
883dffaa00 really fix [3118445] Transform * Transform does not work as expected
Two bugs were counter acting each other.
- rotation matrices are on the left-hand side of multiplies
- the transform of the overlay is applied before that of the layer

Change-Id: Ia79bd368e9b719235c89ecf244ea263f01ce906a
2010-10-27 18:04:11 -07:00
Mathias Agopian
d4a36d5102 am e1ca532d: am 457bed2b: Merge "fix [3123221] Video sticks playing back upside down following orientation switch" into gingerbread
Merge commit 'e1ca532d72cbfacdce794f8bb4d439e609ec9871'

* commit 'e1ca532d72cbfacdce794f8bb4d439e609ec9871':
  fix [3123221] Video sticks playing back upside down following orientation switch
2010-10-25 13:53:33 -07:00
Mathias Agopian
bb35a6322e am b4645353: am ce4d36ad: Merge "fix [3118445] Transform * Transform does not work as expected" into gingerbread
Merge commit 'b4645353090f1bdd5cc1d4ab98feac7ccf966368'

* commit 'b4645353090f1bdd5cc1d4ab98feac7ccf966368':
  fix [3118445] Transform * Transform does not work as expected
2010-10-25 13:53:26 -07:00
Mathias Agopian
a7a8f05d8c am 457bed2b: Merge "fix [3123221] Video sticks playing back upside down following orientation switch" into gingerbread
Merge commit '457bed2bc6561dd67429dde238453fee8602fa9b' into gingerbread-plus-aosp

* commit '457bed2bc6561dd67429dde238453fee8602fa9b':
  fix [3123221] Video sticks playing back upside down following orientation switch
2010-10-25 13:38:15 -07:00
Mathias Agopian
46135ee9a3 am ce4d36ad: Merge "fix [3118445] Transform * Transform does not work as expected" into gingerbread
Merge commit 'ce4d36ad729f83253d4c5ec9906148f45cc00f8e' into gingerbread-plus-aosp

* commit 'ce4d36ad729f83253d4c5ec9906148f45cc00f8e':
  fix [3118445] Transform * Transform does not work as expected
2010-10-25 13:38:11 -07:00
Mathias Agopian
38e5c8ef89 Merge "fix [3123221] Video sticks playing back upside down following orientation switch" into gingerbread 2010-10-25 13:31:11 -07:00
Mathias Agopian
d3caac954c fix [3123221] Video sticks playing back upside down following orientation switch
the overlay wasn't reconfigured when the screen-orientation changed. It was
only done when a parameter of the surface itself changed.

Change-Id: I0ca0925bf58ded4c91ab89d12cb1fe4d1477c96c
2010-10-24 19:03:58 -07:00
Mathias Agopian
0694d0f3b3 fix [3118445] Transform * Transform does not work as expected
The problem wasn't in the multiply operator, but rather in the code
that built the transform from the HAL bitmask.

We now use the multiply operator to build the Transform from the bitmask,
which guarantees, it'll always be correct.

Also added a simple test for Transform.

Change-Id: I09bf3b0e51d92f59d83ea91c4cc94fc2aa0bf227
2010-10-24 14:53:05 -07:00
Mathias Agopian
47a79466a7 am fb31036f: am 583fefc8: Merge "Use the context_priority extension when present." into gingerbread
Merge commit 'fb31036fd844444c395a2ae9c97439eec9f774e4'

* commit 'fb31036fd844444c395a2ae9c97439eec9f774e4':
  Use the context_priority extension when present.
2010-10-21 13:48:36 -07:00
Mathias Agopian
db02bde788 am 583fefc8: Merge "Use the context_priority extension when present." into gingerbread
Merge commit '583fefc8dcadecc7fc933513d3569dd9c16c100c' into gingerbread-plus-aosp

* commit '583fefc8dcadecc7fc933513d3569dd9c16c100c':
  Use the context_priority extension when present.
2010-10-20 21:28:25 -07:00
Mathias Agopian
3c85e4ad5a Merge "Use the context_priority extension when present." into gingerbread 2010-10-20 20:04:46 -07:00
Mathias Agopian
0a96e3c31f am 9f6d18ca: am 04358138: Merge "[3095807] screen takes a long time to turn on" into gingerbread
Merge commit '9f6d18cadf9ac50062063f5f5ff5de7f6895696a'

* commit '9f6d18cadf9ac50062063f5f5ff5de7f6895696a':
  [3095807] screen takes a long time to turn on
2010-10-16 08:58:35 -07:00
Mathias Agopian
fb3051b15e am 7e9a54d4: am d4e03f37: addresses parts of 3096779 and 3097475
Merge commit '7e9a54d460030a871a4f05e61e943c6a694e9ef8'

* commit '7e9a54d460030a871a4f05e61e943c6a694e9ef8':
  addresses parts of 3096779 and 3097475
2010-10-16 08:52:30 -07:00
Mathias Agopian
1cc53746aa am a8faf91f: am 6d71f6a0: Merge "fix [3095607] Gingerbread screen turn-on animation does not show the last frame" into gingerbread
Merge commit 'a8faf91fa558be1235d508e776eb24be4429585c'

* commit 'a8faf91fa558be1235d508e776eb24be4429585c':
  fix [3095607] Gingerbread screen turn-on animation does not show the last frame
2010-10-16 08:52:12 -07:00
Mathias Agopian
c9ce8cbe3b am 3d4a9774: am b0e020ab: Merge "may fix 3097381 and 3097482. don\'t abort on/off if the animation fails" into gingerbread
Merge commit '3d4a9774ced0c704da455c5bd9989127e90ba133'

* commit '3d4a9774ced0c704da455c5bd9989127e90ba133':
  may fix 3097381 and 3097482. don't abort on/off if the animation fails
2010-10-15 14:28:07 -07:00
Mathias Agopian
e33a35f025 am 5bfa3a34: am 011b5bcc: Merge "implement part of [3094280] New animation for screen on and screen off add support for screen on animation" into gingerbread
Merge commit '5bfa3a34eaef759c3ec4def76f646eb1c0bf997f'

* commit '5bfa3a34eaef759c3ec4def76f646eb1c0bf997f':
  implement part of [3094280] New animation for screen on and screen off
2010-10-15 08:33:43 -07:00
Mathias Agopian
65019fdc82 am 04358138: Merge "[3095807] screen takes a long time to turn on" into gingerbread
Merge commit '043581382e43acbe29a8a62420bc765f49a9dd90' into gingerbread-plus-aosp

* commit '043581382e43acbe29a8a62420bc765f49a9dd90':
  [3095807] screen takes a long time to turn on
2010-10-14 16:51:05 -07:00
Mathias Agopian
a6546e5af4 [3095807] screen takes a long time to turn on
turn on animation is now ~200 ms (12 frames).

Change-Id: I49ca9e8d0afa566349d360b3b6c88f0d55aa6e75
2010-10-14 15:39:21 -07:00
Mathias Agopian
af384f8e3b am d4e03f37: addresses parts of 3096779 and 3097475
Merge commit 'd4e03f37423bee383d17f7292753a5f67e497a28' into gingerbread-plus-aosp

* commit 'd4e03f37423bee383d17f7292753a5f67e497a28':
  addresses parts of 3096779 and 3097475
2010-10-14 15:17:16 -07:00
Mathias Agopian
b9d181f46e am 6d71f6a0: Merge "fix [3095607] Gingerbread screen turn-on animation does not show the last frame" into gingerbread
Merge commit '6d71f6a0ae9fd81ce25562aee67f841b5d8394cf' into gingerbread-plus-aosp

* commit '6d71f6a0ae9fd81ce25562aee67f841b5d8394cf':
  fix [3095607] Gingerbread screen turn-on animation does not show the last frame
2010-10-14 15:01:23 -07:00
Mathias Agopian
abd671a08a addresses parts of 3096779 and 3097475
3097475: Animation setting should control the screen on animation
3096779: CRT power-on animation can briefly show the top app instead of lockscreen

There is now a parameter that controls wether the ON and/or OFF animation are
performed. we also always clear the screen to black on power off, to make
sure it won't briefly appear on power on.
HOWEVER, 3096779 is not 100% fixed in the case where we're doing the animation
because there is a race, where SF doesn't wait (b/c it doesn't know) for the
framework to have redrawn the lockscreen.

Change-Id: Ie0f02c9225fcdf24b1e8907e268eb7da2c5b0a03
2010-10-14 14:57:34 -07:00
Mathias Agopian
a310993c83 am b0e020ab: Merge "may fix 3097381 and 3097482. don\'t abort on/off if the animation fails" into gingerbread
Merge commit 'b0e020ab409b725a556f2c5043b08c9bac2c29bf' into gingerbread-plus-aosp

* commit 'b0e020ab409b725a556f2c5043b08c9bac2c29bf':
  may fix 3097381 and 3097482. don't abort on/off if the animation fails
2010-10-14 13:41:28 -07:00
Mathias Agopian
a7f0373533 fix [3095607] Gingerbread screen turn-on animation does not show the last frame
always redraw the screen entirely after the power-on animation, because:
- the animation may not run (ie: on the emu)
- the animation may not contain the video planes
- the interpolation may not be perfect and not land exactly on the last frame

Change-Id: I9ba40f537b1e94464f8a3ed6f81e7c2f552df51d
2010-10-14 12:46:24 -07:00
Mathias Agopian
015fb3fb41 may fix 3097381 and 3097482. don't abort on/off if the animation fails
now that sf handles more of the screen on/off state, we don't want to abort
because/if the animation fails for some reason (which will be the case on the
emulator).

Change-Id: I239e0a39cf8aff3074647e82db92de4a0bf0e494
2010-10-14 12:24:54 -07:00
Joe Onorato
503d2d4a08 am 9a12a3c8: am ba799098: Merge changes I76513387,I335fb671 into gingerbread
Merge commit '9a12a3c8d4bb20042cf69e07d268e3a04ac71f96'

* commit '9a12a3c8d4bb20042cf69e07d268e3a04ac71f96':
  Remove dead code, and make the animation a setting.
  turn off the electron beam
2010-10-13 23:34:21 -07:00
Mathias Agopian
d91595b000 am 011b5bcc: Merge "implement part of [3094280] New animation for screen on and screen off add support for screen on animation" into gingerbread
Merge commit '011b5bcc0355338b7ff906656282a54ffaa04b5a' into gingerbread-plus-aosp

* commit '011b5bcc0355338b7ff906656282a54ffaa04b5a':
  implement part of [3094280] New animation for screen on and screen off
2010-10-13 15:59:42 -07:00
Mathias Agopian
9daa5c9b9d implement part of [3094280] New animation for screen on and screen off
add support for screen on animation

Change-Id: If50cf52ae04b95b42da7d74cf7fa96d5cb54d238
2010-10-13 14:28:26 -07:00
Joe Onorato
296b1d7764 am ba799098: Merge changes I76513387,I335fb671 into gingerbread
Merge commit 'ba799098608c7be8ff1e18adfa7dc1f452205a7e' into gingerbread-plus-aosp

* commit 'ba799098608c7be8ff1e18adfa7dc1f452205a7e':
  Remove dead code, and make the animation a setting.
  turn off the electron beam
2010-10-12 14:46:23 -07:00
Mathias Agopian
59119e658a turn off the electron beam
Change-Id: I335fb6719f1d5a3f1c6f37a046fd1c2c4ed2bbc6
2010-10-12 14:16:11 -07:00
Mathias Agopian
eb8f8980d4 am 5d477279: am cf6b2765: Merge "fix a bug where FLIP_H would do a 180 rotation" into gingerbread
Merge commit '5d477279e6e41c9d61abe66dcded5c57a51e2c78'

* commit '5d477279e6e41c9d61abe66dcded5c57a51e2c78':
  fix a bug where FLIP_H would do a 180 rotation
2010-10-12 13:57:09 -07:00
Mathias Agopian
09e5687757 am 3754d0cc: am d0528b74: Merge "deliver invalidate messages AFTER other messages" into gingerbread
Merge commit '3754d0ccc7ba07fd867d3d28e6493e84ce0a139d'

* commit '3754d0ccc7ba07fd867d3d28e6493e84ce0a139d':
  deliver invalidate messages AFTER other messages
2010-10-12 13:56:58 -07:00
Romain Guy
3b996c96e4 Always create OpenGL accelerated windows in RGBA 8888.
Bug #3081600

The OpenGL renderer in libhwui uses a single EGL context per process and
thus create it with an RGBA 8888 EGL configuration. To ensure that all
windows are compatible with this configuration, this change modifies
the window manager and SurfaceFlinger.

The window manager now checks the window's flags and if the window is
hardware accelerated, it forces the window's pixel format to be
translucent when creating the surface. The window itself is still
marked as opaque if we know that the window will be opaque on screen.
This keeps existing optimizations in place.

Similarly in SurfaceFlinger, a translucent Surface can now be created
with the Surface.OPAQUE flag, indicating SurfaceFlinger that the surface
does not require blending, despite its RGBA 8888 configuration.

Change-Id: Ic747b6b12564ba064412d842117880fcc199eb7c
2010-10-12 11:00:18 -07:00
Mathias Agopian
67226814e1 Use the context_priority extension when present.
Change-Id: I12eadf1e32d576de5d811fba44afa73263e13eef
2010-10-11 18:01:00 -07:00
Mathias Agopian
c6f607dcdd am cf6b2765: Merge "fix a bug where FLIP_H would do a 180 rotation" into gingerbread
Merge commit 'cf6b2765ae7ea6305754e253264012b8f0498f7b' into gingerbread-plus-aosp

* commit 'cf6b2765ae7ea6305754e253264012b8f0498f7b':
  fix a bug where FLIP_H would do a 180 rotation
2010-10-11 14:40:02 -07:00
Mathias Agopian
20f29b4a2a Merge "fix a bug where FLIP_H would do a 180 rotation" into gingerbread 2010-10-11 14:37:57 -07:00
Mathias Agopian
3c2c54c270 fix a bug where FLIP_H would do a 180 rotation
Change-Id: Ie2cc4a8543a5625750c8596f87edcb66fcbca31f
2010-10-11 14:19:24 -07:00
Mathias Agopian
2e109a8666 am d0528b74: Merge "deliver invalidate messages AFTER other messages" into gingerbread
Merge commit 'd0528b74b6de87c415ea498095e142d52c68875b' into gingerbread-plus-aosp

* commit 'd0528b74b6de87c415ea498095e142d52c68875b':
  deliver invalidate messages AFTER other messages
2010-10-11 14:17:25 -07:00
Mathias Agopian
7b0ba16688 deliver invalidate messages AFTER other messages
because invalidate messages were always handled first, they
could prevent other messages to get through entirely.
there is no real reason to handle invalidate messages first because
the other messages are very uncommon and won't interfer with
updates.

Change-Id: Ib95cdf35a91407bd2f4d69dd082c5f546e1e0071
2010-10-11 14:11:15 -07:00
Mathias Agopian
8d5ed61121 am a7c76d83: Merge "fix a bug where timeouts would only be handled when a message was delivered" into gingerbread
Merge commit 'a7c76d8307a3b49bf5b8fdda3543455b0e5dd64c' into gingerbread-plus-aosp

* commit 'a7c76d8307a3b49bf5b8fdda3543455b0e5dd64c':
  fix a bug where timeouts would only be handled when a message was delivered
2010-10-11 12:44:23 -07:00
Mathias Agopian
23a0920339 fix a bug where timeouts would only be handled when a message was delivered
Change-Id: I98c69b129e75e065e61f47e54f0f855d9401b0dc
2010-10-11 12:40:09 -07:00
Mathias Agopian
954fdd27ca fix a bug where timeouts would only be handled when a message was delivered
Change-Id: Id3127b21c1a1a1afab32911a8edbb202360d7c9b
2010-10-07 19:59:06 -07:00
Mathias Agopian
58959343db Fix a null dereference
Change-Id: I3df446b90c1607782778749de7ba0f8c00698c33
2010-10-07 14:57:04 -07:00
Mathias Agopian
6263c831ec am 19058877: Merge "refactored screenshot code" into gingerbread
Merge commit '19058877df9bf94f197a72855f810f7f6bf8d068' into gingerbread-plus-aosp

* commit '19058877df9bf94f197a72855f810f7f6bf8d068':
  refactored screenshot code
2010-10-04 20:06:51 -07:00
Mathias Agopian
df85c455c3 refactored screenshot code
the core screenshot function now can capture the screen at any lower resolution
performing bilinear filtering.

we also now have some client code to interface with the screenshot service.

it's now possible to request a screenshot at a lower resolution.

Change-Id: I33689bba98507ab928d0898b21596d0d2fe4b953
2010-10-04 17:36:17 -07:00
Mathias Agopian
74c40c0a27 refactored screenshot code
the core screenshot function now can capture the screen at any lower resolution
performing bilinear filtering.

we also now have some client code to interface with the screenshot service.

it's now possible to request a screenshot at a lower resolution.

Change-Id: I5a3b0e431421800e3aad601d9af8f94adffbc71f
2010-09-29 16:55:15 -07:00
Mathias Agopian
a3aefeb1c3 am 495ad4f2: am beabe75a: Merge changes I1f7c4535,I741c68a2 into gingerbread
Merge commit '495ad4f22096aa172d025c16c25497e7dad8f2bd'

* commit '495ad4f22096aa172d025c16c25497e7dad8f2bd':
  simple test app for screen capture API
  add support for [1974164] Be able to take a screen shot on the device
2010-09-24 18:13:22 -07:00
Mathias Agopian
c814f965de am beabe75a: Merge changes I1f7c4535,I741c68a2 into gingerbread
Merge commit 'beabe75a842d521b005999460d3a6361ab32108e' into gingerbread-plus-aosp

* commit 'beabe75a842d521b005999460d3a6361ab32108e':
  simple test app for screen capture API
  add support for [1974164] Be able to take a screen shot on the device
2010-09-24 18:07:41 -07:00
Mathias Agopian
06e7056660 simple test app for screen capture API
Change-Id: I1f7c453508ccfd4faaa8b1279968a358ce3f1e5a
2010-09-24 15:01:49 -07:00
Mathias Agopian
1b0b30d043 add support for [1974164] Be able to take a screen shot on the device
screenshots are taken using ISurfaceComposer::captureScreen() which returns
the size of the screenshot and an IMemoryHeap containing the data.
screenshots have limitations:
- they will always fail if a secure window is up on screen
- require GL_OES_framebuffer_object extension
- in some situation, video planes won't been captured

Change-Id: I741c68a2d2984fb139039301c3349e6780e2cd58
2010-09-24 14:56:39 -07:00
Mathias Agopian
8372785879 dump HWC state in dumpsys
Change-Id: Ifbb38ca1ac9685776250e01c8d02021b35af72cf
2010-09-23 18:13:21 -07:00
Mathias Agopian
73d3ba9e50 add a way to toggle the h/w composer at runtime
to DISABLE the h/w composer:
  adb shell service call SurfaceFlinger 1008 i32 1

to ENABLE the h/w composer:
  adb shell service call SurfaceFlinger 1008 i32 0

the state is dumped in "dumpsys SurfaceFlinger"

Change-Id: I23e2242d42c6e3fd5261a83332dd900b189e38ce
2010-09-22 18:58:01 -07:00
Mathias Agopian
e44d21a247 fix [3018216] UI shrinks / stretches while using apps with IME
Change-Id: Ie4c5d8a434b4489355ed8c52af96eb931b4d7167
2010-09-21 10:52:42 -07:00
Jamie Gennis
9c2de1a4b5 Merge "Fix a SurfaceFlinger bug." 2010-09-17 14:07:13 -07:00
Jamie Gennis
5dda7f7cf2 Fix a SurfaceFlinger bug.
The bug caused SurfaceFlinger to constantly trigger reallocation of buffers
that requested a fixed size.

Change-Id: Ic993a60e6474e36a344c8b48d541a0d08b8c4faf
2010-09-17 12:19:07 -07:00
Mathias Agopian
fe0a0af7bd am 793b2293: am 1bcb8b1a: Merge "surfaceflinger / GL extensions cleanup" into gingerbread
Merge commit '793b2293797ea930078640c4827d3cbdf449c227'

* commit '793b2293797ea930078640c4827d3cbdf449c227':
  surfaceflinger / GL extensions cleanup
2010-09-16 18:26:19 -07:00
Mathias Agopian
c05246ae34 am 1bcb8b1a: Merge "surfaceflinger / GL extensions cleanup" into gingerbread
Merge commit '1bcb8b1afbfa2fc387a0f7068740f1efbe9a1f69' into gingerbread-plus-aosp

* commit '1bcb8b1afbfa2fc387a0f7068740f1efbe9a1f69':
  surfaceflinger / GL extensions cleanup
2010-09-16 17:57:34 -07:00
Michael I. Gold
7f198b6bff surfaceflinger / GL extensions cleanup
Add correct enumerants for OES_EGL_image_external to glext.h.
SurfaceFlinger now checks for the correct extension name.

Change-Id: I2ba2728a01fa2260bd086d2df4316c68f694a9b1
2010-09-15 17:15:31 -07:00
Mathias Agopian
c479e18db0 resolved conflicts for merge of 48a86240 to master
Change-Id: I2305fef9f4dd46183337217d822df3c675b6b6e5
2010-09-15 12:29:18 -07:00
Mathias Agopian
5e4cf02dfe am b3ffc78f: Merge "Add logging of various important graphics events" into gingerbread
Merge commit 'b3ffc78f3432344702e6f5232067ab624083cad2' into gingerbread-plus-aosp

* commit 'b3ffc78f3432344702e6f5232067ab624083cad2':
  Add logging of various important graphics events
2010-09-14 15:14:10 -07:00
Mathias Agopian
35b48d10bc Add logging of various important graphics events
There are 16 events logged in the event log:
SF_APP_DEQUEUE_BEFORE
SF_APP_DEQUEUE_AFTER
SF_APP_LOCK_BEFORE
SF_APP_LOCK_AFTER
SF_APP_QUEUE

SF_REPAINT
SF_COMPOSITION_COMPLETE
SF_UNLOCK_CLIENTS
SF_SWAP_BUFFERS
SF_REPAINT_DONE

SF_FB_POST_BEFORE
SF_FB_POST_AFTER
SF_FB_DEQUEUE_BEFORE
SF_FB_DEQUEUE_AFTER
SF_FB_LOCK_BEFORE
SF_FB_LOCK_AFTER

all events log the buffer conserned and a timestamp in microseconds.

by default the logging is not enabled, to turn it on:
adb shell service call SurfaceFlinger 1006 i31 1
adb shell setprop debug.graphic_log 1

The effect is immediate in SurfaceFlinger, but applications need to be
restarted.

Change-Id: Ifc2e31f7aed072d9a7dede20ff2ce59231edbec1
2010-09-13 23:16:58 -07:00
Antti Hatala
f5f2712854 surfaceflinger: give hwcomposer a chance to release buffers
Change-Id: I605fa779702022865dd58df3b36f37c2644ade36
2010-09-09 12:06:48 -07:00
Antti Hatala
586a0deb76 surfaceflinger: composite HWC_SKIP_LAYER layers
Change-Id: I363ede63287ae903d66d0d419343f4ecd81bcc00
2010-09-09 12:06:31 -07:00
Antti Hatala
8392b504bd surfaceflinger: unlock clients only after flip
Change-Id: I039291a36f05bbaa02b29325d4012114abd784b9
2010-09-09 12:06:18 -07:00
Mathias Agopian
413f750501 am 6d4346ce: am 4cffbb47: Merge "fix [2946787] Screen flicker on low resolution setting in camcorder." into gingerbread
Merge commit '6d4346ce35a521d67f45d7c9658c450c0fc461d2'

* commit '6d4346ce35a521d67f45d7c9658c450c0fc461d2':
  fix [2946787] Screen flicker on low resolution setting in camcorder.
2010-08-25 16:40:28 -07:00
Mathias Agopian
9cca403ed0 am 4cffbb47: Merge "fix [2946787] Screen flicker on low resolution setting in camcorder." into gingerbread
Merge commit '4cffbb47a28faa594c2217d1e84f9382e0b57cc4' into gingerbread-plus-aosp

* commit '4cffbb47a28faa594c2217d1e84f9382e0b57cc4':
  fix [2946787] Screen flicker on low resolution setting in camcorder.
2010-08-25 15:40:44 -07:00
Mathias Agopian
eff062c49e fix [2946787] Screen flicker on low resolution setting in camcorder.
Change-Id: I7e86f2b6d85dcae8dd212890b978fa6ac7de6893
2010-08-25 15:09:52 -07:00
Mathias Agopian
e34a3d1a29 am 46820412: am 8eb16af2: Merge "don\'t try to lock a buffer that wasn\'t allocated with SW usage bits" into gingerbread
Merge commit '468204124e95bbf74ae8cc000318ade29e311be6'

* commit '468204124e95bbf74ae8cc000318ade29e311be6':
  don't try to lock a buffer that wasn't allocated with SW usage bits
2010-08-25 12:24:02 -07:00
Mathias Agopian
2091772e7c am 8eb16af2: Merge "don\'t try to lock a buffer that wasn\'t allocated with SW usage bits" into gingerbread
Merge commit '8eb16af29303cda190133a1d220b9ecd9341e261' into gingerbread-plus-aosp

* commit '8eb16af29303cda190133a1d220b9ecd9341e261':
  don't try to lock a buffer that wasn't allocated with SW usage bits
2010-08-25 12:17:19 -07:00
Mathias Agopian
f1b38247d4 don't try to lock a buffer that wasn't allocated with SW usage bits
Change-Id: Iabbcec1bfa30dc47d45ece699dd178653f1b675b
2010-08-25 12:14:27 -07:00
Mathias Agopian
4ad298c12c am bc4389ed: am 8395b462: Merge "fix [2931513] Add support for setting the orientation of an ANativeWindow" into gingerbread
Merge commit 'bc4389edfbb5777aec1a9af7863b2ca3ade2fa64'

* commit 'bc4389edfbb5777aec1a9af7863b2ca3ade2fa64':
  fix [2931513] Add support for setting the orientation of an ANativeWindow
2010-08-24 17:56:40 -07:00
Mathias Agopian
95acdcc7de am 8395b462: Merge "fix [2931513] Add support for setting the orientation of an ANativeWindow" into gingerbread
Merge commit '8395b4625b96f2133e2e4f595fdc69fbe222e4fc' into gingerbread-plus-aosp

* commit '8395b4625b96f2133e2e4f595fdc69fbe222e4fc':
  fix [2931513] Add support for setting the orientation of an ANativeWindow
2010-08-24 16:28:57 -07:00