Commit Graph

1413 Commits

Author SHA1 Message Date
Zhijun He b4b63704c0 CpuConsumer: Add set buffer size and format functions.
Add setDefaultBufferSize() and setDefaultBufferFormat(). ImageReader JNI need
them.

Bug: 9254294
Change-Id: I7d2464d43b0ca73fbb834ed22cecbfbb30eef60c
2013-06-10 13:34:01 -07:00
Zhijun He ae772278fe CpuConsumer: Remove CpuConsumer JNI ID.
Not used anywhere, and it is pretty confusing to have it here.

Bug: 9254294
Change-Id: I12b761532918b546a0f56c74ccf81b2c119ccd66
2013-06-03 10:42:05 -07:00
Michael Wright ae4d9dd0da Merge "Added bitwise-or and bitwise-and to BitSet" 2013-05-31 03:31:49 +00:00
Michael Wright 24beb02a7a Added bitwise-or and bitwise-and to BitSet
Change-Id: I9bbf41f9d2d4a2593b0e6d7d8be7e283f985bade
2013-05-30 18:40:04 -07:00
Jeff Sharkey 05431a94d4 Merge "Bring back overloading to print String8/16." 2013-05-30 21:33:36 +00:00
Andrew Hsieh fa7d40331c am 75765d3a: am 1c45dc66: Merge "Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event"
* commit '75765d3af58ad7ed97c0d646c936294ba861848f':
  Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event
2013-05-30 14:23:56 -07:00
Jeff Sharkey 8cb8925921 Bring back overloading to print String8/16.
Change-Id: Iecab20db2b8574d5f1e6fdefdc2c8d4ce6c37121
2013-05-30 14:04:28 -07:00
Andrew Hsieh 75765d3af5 am 1c45dc66: Merge "Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event"
* commit '1c45dc66c77f0ddb246a55d780206a183740ff7f':
  Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event
2013-05-29 18:33:33 -07:00
Andrew Hsieh 1c45dc66c7 Merge "Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event" 2013-05-30 01:30:48 +00:00
Jeff Brown ad8ce82396 am 31ab96fc: am 135e4dbd: Merge "utils: Allow non android namespaces to use ALOGD_IF_SLOW"
* commit '31ab96fcc1810e044f8bdb35d3bfbbba2fa6bafd':
  utils: Allow non android namespaces to use ALOGD_IF_SLOW
2013-05-28 15:52:26 -07:00
Jeff Brown 31ab96fcc1 am 135e4dbd: Merge "utils: Allow non android namespaces to use ALOGD_IF_SLOW"
* commit '135e4dbd65d49730fbd6f830de7b303e01d20d5f':
  utils: Allow non android namespaces to use ALOGD_IF_SLOW
2013-05-28 15:46:03 -07:00
Jeff Brown 135e4dbd65 Merge "utils: Allow non android namespaces to use ALOGD_IF_SLOW" 2013-05-28 20:20:15 +00:00
Andrew Hsieh 26c2416281 Fix AMotionEvent_getHistorical* to take const AInputEvent* motion_event
See b.android.com/55873

Change-Id: I92c549e1a595662d4df8fa0e47675ccb2b8814fd
2013-05-27 12:26:04 +08:00
Lajos Molnar 9e3cb55b8f BufferQueue: remove freeAllBuffersExceptHeadLocked()
Now that we are having separate buffer-instances for the buffer-
queue, we can free all buffers; we don't have to keep the head
alive.

Change-Id: I023e9161a2501d99333f8868ce438afa914ec50f
Signed-off-by: Lajos Molnar <lajos@google.com>
Related-to-bug: 7093648
2013-05-23 22:21:13 +00:00
Lajos Molnar c5d7b7d323 BufferQueue: track buffer-queue by instance vs. by reference
Instead of representing the buffer-queue as a vector of buffer
indices, represent them as a vector of BufferItems (copies).
This allows modifying the buffer slots independent of the queued
buffers.

As part of this change, BufferSlot properties that are only
been relevant in the buffer-queue have been removed.

Also, invalid scalingMode in queueBuffer now returns an error.

ConsumerBase has also changed to allow reuse of the same
buffer slots by different buffers.

Change-Id: If2a698fa142b67c69ad41b8eaca6e127eb3ef75b
Signed-off-by: Lajos Molnar <lajos@google.com>
Related-to-bug: 7093648
2013-05-23 22:17:54 +00:00
Tim Murray d837969640 Make trace macros slightly more robust
Change-Id: I9544eb7b27fc1a971cabadd8d5b4b4b80678febf
2013-05-23 13:44:08 -07:00
Dianne Hackborn 80d7fd86e0 Power manager now takes calling package name arg.
Change-Id: Iae57b8eb7abe4e66f0d2645db8cdf57acf7dcd3e
2013-05-20 16:50:10 -07:00
Chong Zhang cb5368356e Merge "wifi-display: add support for metadata mode on encoder output" 2013-05-18 00:02:10 +00:00
Mathias Agopian 2381033ad0 am e6eef6c1: am ea74d3b7: make the warning timout of Fence::waitForever() implicit and longer
* commit 'e6eef6c136b007f3a7e1e19884875b855c0c5f95':
  make the warning timout of Fence::waitForever() implicit and longer
2013-05-17 10:18:45 -07:00
Mathias Agopian ea74d3b78d make the warning timout of Fence::waitForever() implicit and longer
- timeout is now 3 seconds instead of 1
- simplifies the API a bit
- allows us to change/tweak this timeout globaly

Bug: 8988871

Change-Id: I8d3c6ec43a372f602fb3f29856710339f86c0ec9
2013-05-16 18:15:57 -07:00
Chong Zhang 685e68130b wifi-display: add support for metadata mode on encoder output
Bug: 8968123

Change-Id: I3d2b567d4908f5f49c0694589920babe1f6752cd
2013-05-16 15:58:31 -07:00
Mathias Agopian f3e85d4327 take the "transparent region" into account for blending
until now it was only used to discard a layer entirely.
we're now reducing the size of the layer if it is still
visible, if possible.

this works for instance when a surfaceView is used and
only the menu bar is displayed over it.

Change-Id: I3f5527c5cd1e69ecc968272c8948f1513ada8c55
2013-05-10 18:35:43 -07:00
Mathias Agopian 6c7f25afb7 reformat Rect.{cpp|h}
Change-Id: I45b1f6646541a1abacce1e70df00a770e47b820e
2013-05-10 18:03:31 -07:00
Mathias Agopian b6df7d0e4c make all libsurfaceflinger and libsensorservice symbols's visibility hidden
we only export the main entry-point.
this saves about 150KB.

Change-Id: I55eb2b6705386fdfa43860deb62f9cdd2a0982aa
2013-05-09 16:51:37 -07:00
Mathias Agopian 5d85d72a17 remove unused declarations and reformat
Change-Id: I4e168fb62c275e02621c4b6e0c6000d0f006c327
2013-05-09 14:57:05 -07:00
Mathias Agopian a6cb0397da remove reserved virtual slots
these consume small amount of space (plt) in every library that
links against libutils.

Change-Id: I1b6b3dd9098aa5a051243f7a5dbf91cd7dcb8b2c
2013-05-09 14:57:05 -07:00
Eino-Ville Talvala d487ca1ab3 am 87ab83d9: am f743e3db: Merge "Add support for HAL_PIXEL_FORMAT_YCbCr_420_888" into jb-mr2-dev
* commit '87ab83d96b9d826e94a7169a6205bcf9c2ee633a':
  Add support for HAL_PIXEL_FORMAT_YCbCr_420_888
2013-05-09 10:19:01 -07:00
Eino-Ville Talvala f743e3db27 Merge "Add support for HAL_PIXEL_FORMAT_YCbCr_420_888" into jb-mr2-dev 2013-05-09 17:13:22 +00:00
Mathias Agopian 57e5144a31 Merge "new String8, String16 ctors to initialize empty static strings with static linkage" 2013-05-09 01:13:51 +00:00
Mathias Agopian 8050299f5b new String8, String16 ctors to initialize empty static strings with static linkage
when libutils is statically linked, the ordering of the static
initializer is not guaranteed and therefore it's unsafe to use
empty static strings: e.g.:

static String8 sThisStaticStringIsNotSafe;

instead, this new constructor can be used:

static String8 sThisStaticStringIsSafe(kEmptyString);

Change-Id: Ia3daf1cab1c97d021c0ee9c2b394b5e27e8d6c0d
2013-05-08 18:13:07 -07:00
Jeff Tinker dc1b01141f am 2c228354: am b84d1cad: Correct native API documentation related to MediaDrm offline use case
* commit '2c2283549c72184145c9f030bbfe6124ee75d169':
  Correct native API documentation related to MediaDrm offline use case
2013-05-08 15:03:40 -07:00
Mathias Agopian 002e1e58df libutils clean-up
Change-Id: I6ff4cfc736751de2912c697f954e45e275f2d386
2013-05-07 18:28:11 -07:00
Jeff Tinker b84d1cad1d Correct native API documentation related to MediaDrm offline use case
These doc updates were made previously to the java API but some
did not make it into the native API.

Change-Id: I9b7bfcd77bc593685254baca1c148deb7e1f91c7
related-to-bug: 8621588
2013-05-07 15:16:40 -07:00
Dianne Hackborn ffad7d1fdc Add new Looper API to check whether the looper is idle.
This is just to support the watchdog to give it a faster
way to determine if a thread is deadlocked without having
to post a message to it.

Change-Id: I068dc8b9387caf94fe5811fb4aeb0f9b57b1a080
2013-05-07 15:05:34 -07:00
Eino-Ville Talvala c43946b931 Add support for HAL_PIXEL_FORMAT_YCbCr_420_888
- Add fields to CpuConsumer::LockedBuffer for new information
- New lock methods for GraphicBuffer and GraphicBufferMapper for
  the format

Bug: 8734880
Change-Id: If31f82c62d64b6942cf4cc6e5715585c03273f12
2013-05-06 17:24:05 -07:00
Mathias Agopian bdcf1fe2ba Merge changes I0d9f18d1,Ib96c9161
* changes:
  Add a --color option to dumpsys SurfaceFlinger
  clean-up/simplify all dump() APIs
2013-04-24 10:25:34 +00:00
Mathias Agopian 6bbd8e30b5 am 3cf76aff: am e692ab9a: fix uninitialized variables in GLConsumer
* commit '3cf76affd3ef28759789622e9e0134bdb045418b':
  fix uninitialized variables in GLConsumer
2013-04-23 11:16:44 -07:00
Mathias Agopian 74d211ae26 clean-up/simplify all dump() APIs
remove the scratch buffer parameter and use
String8::appendFormat() instead.

Change-Id: Ib96c91617c8e7292de87433d15cf6232b7d591b0
2013-04-22 21:51:28 +02:00
Mathias Agopian e692ab9a6b fix uninitialized variables in GLConsumer
mDefaultWidth, mDefaultHeight and mCurrentScallingMode are now
initialized to the same default value that BufferQueue uses.

Change-Id: I0d4da2022b06419d12745716d8ddbd48c8869953
2013-04-22 11:24:02 +02:00
Igor Murashkin 6ca04ca755 am f3d93d43: am 187edf93: Merge "BufferItemConsumer: add functions to set default buffer format/size" into jb-mr2-dev
* commit 'f3d93d436373dcc39ff0b7f4aac938f4619421a2':
  BufferItemConsumer: add functions to set default buffer format/size
2013-04-17 12:48:23 -07:00
Igor Murashkin 187edf93c6 Merge "BufferItemConsumer: add functions to set default buffer format/size" into jb-mr2-dev 2013-04-17 19:39:53 +00:00
Igor Murashkin 87d1e3427b BufferItemConsumer: add functions to set default buffer format/size
Bug: 8629088
Change-Id: I06f2e26a70d6dbcfcd70b08b4461e8e401f6e83f
2013-04-16 11:24:40 -07:00
Rom Lemarchand 1bc7e2f6dd Add support for OMX_QCOM_COLOR_FormatYUV420PackedSemiPlanar32m color format
Change-Id: I9392eb961ec92d4d778573b7a142344e552c80d6
2013-04-11 10:30:27 -07:00
Andy McFadden 53dc9044bf Merge "Updated comments" into jb-mr2-dev 2013-04-11 17:15:52 +00:00
Jamie Gennis 8758a3e394 Merge changes I82e361a6,I83694682 into jb-mr2-dev
* changes:
  libgui_test: increase the tolerance for a YUV test
  libgui: fix an EGLImage leak
2013-04-09 21:43:20 +00:00
Jamie Gennis ad669b04f4 libgui: fix an EGLImage leak
This moves the call to ConsumerBase::abandon from the ConsumerBase dtor to
ConsumerBase::onLastStrongRef.  The abandon call relies on virtual methods to
perform the clean-up, so calling it from the ConsumerBase dtor after the
derived classes dtors ran was skipping some of the clean-up.  The
onLastStrongRef method should get called just before the most derived class's
dtor gets called.

Bug: 8349135
Change-Id: I836946826927cc1ed69c049049f525f92b17a269
2013-04-08 14:42:22 -07:00
Andy McFadden 753e3415cd Updated comments
Updated many comments.  Added one minor error check.

Change-Id: Ib935dd99d417bada91d2e198008a50dd94269316
2013-04-05 10:44:23 -07:00
Jeff Tinker 18bd1d6d55 Merge "Implement async event callout from drm plugin to Java app" into jb-mr2-dev 2013-04-05 01:16:21 +00:00
Jeff Tinker 7eafcae5ff Implement async event callout from drm plugin to Java app
Change-Id: I83a7757a7b83676ce1a9ffa6ff0a8e495e31b859
2013-04-03 12:02:59 -07:00
Mathias Agopian 2ca79399b9 latch transparent region hint only when we get a new frame
since the transparent region hint really depends on the
content of the window containing the SurfaceView
(it's calculated by the view hierarchy based on
overlapping views), it makes sense to latch it only when
the content of the window (the app) changes.

This should help fixing drawing artifacts when changing the
layout of a window containing a SurfaceView.

Bug: 8511430
Change-Id: Ic3aa668495293cb4d82a2cd7dcf3b6a337287678
2013-04-02 18:30:32 -07:00