3297 Commits

Author SHA1 Message Date
Alex Sakhartchouk
415c842aa6 Merge "rsLib cleanup" 2011-05-12 10:15:17 -07:00
Mathias Agopian
e845c352c8 fix onFrameAvailable
Change-Id: I391fe9f6684ac9fd4f91416ce18b583f7087d966
2011-05-11 18:01:51 -07:00
Mathias Agopian
7f3289c95e Add SurfaceTexture logging
Change-Id: If1b74be5230813fb76429935d88b9d4a7c41700c
2011-05-11 18:01:51 -07:00
Mathias Agopian
402ff24aa1 Implement {Surface|SurfaceTextureClient}::setSwapInterval()
Change-Id: I8382e346ddaa2c4c8ff56ac3ffd7f0109572f188
2011-05-11 18:01:51 -07:00
Mathias Agopian
a6b717b52a new tests for SurfaceTexture synchronous mode
Change-Id: Icfdaa625238246f8d0224efe28fdf2c1c24203f8
2011-05-11 18:01:51 -07:00
Mathias Agopian
5bbb1cf9d7 Add the concept of synchronous dequeueBuffer in SurfaceTexture
Change-Id: Ic94cbab092953243a0746e04bbe1b2eb0cc930ef
2011-05-11 18:01:51 -07:00
Mathias Agopian
ed3894c07a unify SurfaceTexture and Surface
Change-Id: I49da2f5d8408e4cd7e148cfb777bb4ff68cd8f37
2011-05-11 18:01:51 -07:00
Mathias Agopian
0297dcae8f Fix a bug where setgeometry couldn't be undone
This change the binder protocol between SurfaceTextureClient
and SurfaceTexture. dequeueBuffer() now takes the requested
parameters for the buffer. SurfaceTexture decides if the
buffer needs to be reallocated and does the allocation
if needed. In that case it returns BUFFER_NEEDS_REALLOCATION
to tell SurfaceTextureClient that it needs to call
requestBuffer (which all parameters have been removed) to
acquire a pointer to the buffer.

dequeueBuffer and requestBuffer could be folded into a single
IPC call, but we chose to optimize the case where buffers are
not created and avoid some complexity in the marshalling code.

Change-Id: I097a7f6f40a3491e10f3f3742eab33999286c304
2011-05-11 18:01:51 -07:00
Conley Owens
5911f958e8 am 041aa34e: am 87d86044: am bcd029b6: Merge "Add missing clean-up of idmap file descriptors."
* commit '041aa34e089d7b194a5d93c682c3af3d3116d3f3':
  Add missing clean-up of idmap file descriptors.
2011-05-11 13:10:56 -07:00
Christopher Tate
a0f5bb10a5 Merge "Full local backup infrastructure" 2011-05-11 12:51:31 -07:00
Christopher Tate
4a627c71ff Full local backup infrastructure
This is the basic infrastructure for pulling a full(*) backup of the
device's data over an adb(**) connection to the local device.  The
basic process consists of these interacting pieces:

1. The framework's BackupManagerService, which coordinates the
   collection of app data and routing to the destination.

2. A new framework-provided BackupAgent implementation called
   FullBackupAgent, which is instantiated in the target applications'
   processes in turn, and knows how to emit a datastream that contains
   all of the app's saved data files.

3. A new shell-level program called "bu" that is used to bridge from
   adb to the framework's Backup Manager.

4. adb itself, which now knows how to use 'bu' to kick off a backup
   operation and pull the resulting data stream to the desktop host.

5. A system-provided application that verifies with the user that
   an attempted backup/restore operation is in fact expected and to
   be allowed.

The full agent implementation is not used during normal operation of
the delta-based app-customized remote backup process.  Instead it's
used during user-confirmed *full* backup of applications and all their
data to a local destination, e.g. via the adb connection.

The output format is 'tar'.  This makes it very easy for the end
user to examine the resulting dataset, e.g. for purpose of extracting
files for debug purposes; as well as making it easy to contemplate
adding things like a direct gzip stage to the data pipeline during
backup/restore.  It also makes it convenient to construct and maintain
synthetic backup datasets for testing purposes.

Within the tar format, certain artificial conventions are used.
All files are stored within top-level directories according to
their semantic origin:

apps/pkgname/a/  : Application .apk file itself
apps/pkgname/obb/: The application's associated .obb containers
apps/pkgname/f/  : The subtree rooted at the getFilesDir() location
apps/pkgname/db/ : The subtree rooted at the getDatabasePath() parent
apps/pkgname/sp/ : The subtree rooted at the getSharedPrefsFile() parent
apps/pkgname/r/  : Files stored relative to the root of the app's file tree
apps/pkgname/c/  : Reserved for the app's getCacheDir() tree; not stored.

For each package, the first entry in the tar stream is a file called
"_manifest", nominally rooted at apps/pkgname.  This file contains some
metadata about the package whose data is stored in the archive.

The contents of shared storage can optionally be included in the tar
stream. It is placed in the synthetic location:

shared/...

uid/gid are ignored; app uids are assigned at install time, and the
app's data is handled from within its own execution environment, so
will automatically have the app's correct uid.

Forward-locked .apk files are never backed up.  System-partition
.apk files are not backed up unless they have been overridden by a
post-factory upgrade, in which case the current .apk *is* backed up --
i.e. the .apk that matches the on-disk data.  The manifest preceding
each application's portion of the tar stream provides version numbers
and signature blocks for version checking, as well as an indication
of whether the restore logic should expect to install the .apk before
extracting the data.

System packages can designate their own full backup agents.  This is
to manage things like the settings provider which (a) cannot be shut
down on the fly in order to do a clean snapshot of their file trees,
and (b) manage data that is not only irrelevant but actively hostile
to non-identical devices -- CDMA telephony settings would seriously
mess up a GSM device if emplaced there blind, for example.

When a full backup or restore is initiated from adb, the system will
present a confirmation UI that the user must explicitly respond to
within a short [~ 30 seconds] timeout.  This is to avoid the
possibility of malicious desktop-side software secretly grabbing a copy
of all the user's data for nefarious purposes.

(*) The backup is not strictly a full mirror.  In particular, the
    settings database is not cloned; it is handled the same way that
    it is in cloud backup/restore.  This is because some settings
    are actively destructive if cloned onto a different (or
    especially a different-model) device: telephony settings and
    AndroidID are good examples of this.

(**) On the framework side it doesn't care that it's adb; it just
    sends the tar stream to a file descriptor.  This can easily be
    retargeted around whatever transport we might decide to use
    in the future.

KNOWN ISSUES:

* the security UI is desperately ugly; no proper designs have yet
  been done for it
* restore is not yet implemented
* shared storage backup is not yet implemented
* symlinks aren't yet handled, though some infrastructure for
  dealing with them has been put in place.

Change-Id: Ia8347611e23b398af36ea22c36dff0a276b1ce91
2011-05-10 17:52:51 -07:00
Jason Sams
ed0fd52301 Merge "Add code for generating fifo command packing." 2011-05-10 16:46:35 -07:00
Conley Owens
041aa34e08 am 87d86044: am bcd029b6: Merge "Add missing clean-up of idmap file descriptors."
* commit '87d86044c0f15ae2ffc0350271c76ff874fb413b':
  Add missing clean-up of idmap file descriptors.
2011-05-10 16:19:29 -07:00
Dianne Hackborn
aa9d84c37e resolved conflicts for merge of 05be6d6f to master
Change-Id: Ic6a6c5bb300f6f1d43f9ed550b284282b4f16212
2011-05-09 19:00:59 -07:00
Dianne Hackborn
05be6d6fe0 am 4907d1d5: am 0c6cbf41: Merge "Better compat mode part one: start scaling windows." into honeycomb-mr2
* commit '4907d1d5e2c7d244b07579b8c52153df69754e85':
  Better compat mode part one: start scaling windows.
2011-05-09 17:10:34 -07:00
Dianne Hackborn
e2515eebf4 Better compat mode part one: start scaling windows.
First step of improving app screen size compatibility mode.  When
running in compat mode, an application's windows are scaled up on
the screen rather than being small with 1:1 pixels.

Currently we scale the application to fill the entire screen, so
don't use an even pixel scaling.  Though this may have some
negative impact on the appearance (it looks okay to me), it has a
big benefit of allowing us to now treat these apps as normal
full-screens apps and do the normal transition animations as you
move in and out and around in them.

This introduces fun stuff in the input system to take care of
modifying pointer coordinates to account for the app window
surface scaling.  The input dispatcher is told about the scale
that is being applied to each window and, when there is one,
adjusts pointer events appropriately as they are being sent
to the transport.

Also modified is CompatibilityInfo, which has been greatly
simplified to not be so insane and incomprehendible.  It is
now simple -- when constructed it determines if the given app
is compatible with the current screen size and density, and
that is that.

There are new APIs on ActivityManagerService to put applications
that we would traditionally consider compatible with larger screens
in compatibility mode.  This is the start of a facility to have
a UI affordance for a user to switch apps in and out of
compatibility.

To test switching of modes, there is a new variation of the "am"
command to do this: am screen-compat [on|off] [package]

This mode switching has the fundamentals of restarting activities
when it is changed, though the state still needs to be persisted
and the overall mode switch cleaned up.

For the few small apps I have tested, things mostly seem to be
working well.  I know of one problem with the text selection
handles being drawn at the wrong position because at some point
the window offset is being scaled incorrectly.  There are
probably other similar issues around the interaction between
two windows because the different window coordinate spaces are
done in a hacky way instead of being formally integrated into
the window manager layout process.

Change-Id: Ie038e3746b448135117bd860859d74e360938557
2011-05-09 17:03:24 -07:00
Alex Sakhartchouk
407cae9503 rsLib cleanup
Change-Id: Ifb66059338e3435ac79435296a650c44699921aa
2011-05-06 14:59:45 -07:00
Jason Sams
7a22e107d1 Add code for generating fifo command packing.
Change-Id: I2d2ef095344b200b10457de96ae1d85821edc91e
2011-05-06 14:30:52 -07:00
Chet Haase
c54ed966f7 Minor javadoc enhancements
Change-Id: Ic24bb0e1e669989f0cae3a9b8fa064b38c8e7948
2011-05-06 14:14:20 -07:00
Chet Haase
3825fef300 Merge "Fix for scaled AA lines" 2011-05-06 13:51:09 -07:00
Chet Haase
99ecdc480d Fix for scaled AA lines
Previously, the translucent boundary of AA lines would be scaled
by the line's transform. It should always be exactly one pixel wide
in screen space. This fix accounts for scaling for the boundary
region, and fixes some AA calculations that make wide/AA lines
more correct.

Change-Id: I30df2d5d96315bf3e7ff30be9735282fd5439a39
2011-05-06 12:10:54 -07:00
Alex Sakhartchouk
438505431c Moving samplers behind the hal.
Change-Id: I494e5a9d2b599d07b985328b346f1f10ae4972e1
2011-05-05 16:56:27 -07:00
Alex Sakhartchouk
19c5c7a7bc Merge "Code Cleanup and better Sampler creation method" 2011-05-05 09:38:00 -07:00
Chet Haase
ed30fd8e9a Add ability for hierarchyviewer to output displaylist info
Clicking on a node in hierarchyviewer1 and hierarchyviewer2 and then
clicking the new "Dump DisplayList" button will cause the display
list for the selected node (including its children) to be output into
logcat.

Change-Id: Iad05f5f6cca0f8b465dccd962b501dc18fe6e053
2011-05-05 07:35:40 -07:00
Mårten Kongstad
2b91c67137 Add missing clean-up of idmap file descriptors.
Change-Id: I9bdc9a4b7962f1a8dce77f4b213c8b9dc26e4b0f
2011-05-05 15:38:14 +02:00
Chet Haase
a17de9b493 Revert "Add ability for hierarchyviewer to output displaylist info"
This reverts commit b2a4b52e8d5e499d33e2765e8c47851bf0266299.
2011-05-04 18:23:12 -07:00
Alex Sakhartchouk
a89094aa3b Code Cleanup and better Sampler creation method
Change-Id: I9e35081ee6034cb619f43a47f8f22f38977f5d12
2011-05-04 17:45:36 -07:00
Chet Haase
42a3a39e23 Merge "Add ability for hierarchyviewer to output displaylist info" 2011-05-04 17:30:30 -07:00
Chet Haase
b2a4b52e8d Add ability for hierarchyviewer to output displaylist info
Clicking on a node in hierarchyviewer1 and hierarchyviewer2 and then
clicking the new "Dump DisplayList" button will cause the display
list for the selected node (including its children) to be output into
logcat.

Change-Id: Id32f62569ad1ab4d533bc62987f3a7390c1bb4e6
2011-05-04 17:18:27 -07:00
Jason Sams
2698536b3f Fix error checks on compute context creation.
Remove GL init for compute scripts.

Change-Id: I1bce8e4112babf4345fa56a30a9bed753734d8d6
2011-05-03 17:27:26 -07:00
Iliyan Malchev
b2a153adc9 frameworks/base: android_native_buffer_t -> ANativeWindowBuffer
Change-Id: Idc2eabaa805bb6d308ebb315872623f28d428417
Signed-off-by: Iliyan Malchev <malchev@google.com>
2011-05-03 16:40:14 -07:00
Iliyan Malchev
4d7c1ce651 frameworks/base: make the ANativeWindow query() method const
query() does not modify the object's data, so it needs to be a const method

Change-Id: I67c40a3c865461e6f1cc2193fd2d74286ff6ac8f
Signed-off-by: Iliyan Malchev <malchev@google.com>
2011-05-03 15:49:40 -07:00
Jason Sams
629b565162 Merge "Try fixing auto data inlining again." 2011-05-03 14:52:22 -07:00
Eino-Ville Talvala
3723396c7a Merge "Add an auto-exposure lock feature to the Camera API." 2011-05-03 11:07:33 -07:00
Romain Guy
df0a7fbdcf Merge "Allows to render with an OpenGL context inside a TextureView." 2011-05-02 18:33:26 -07:00
Romain Guy
8f0095cd33 Allows to render with an OpenGL context inside a TextureView.
Change-Id: I59453f7fc3997f0502a1c5d325d37fed376fabc7
2011-05-02 18:32:29 -07:00
Jason Sams
b96e9517af Try fixing auto data inlining again.
Change-Id: I95113db85551cbee774250eacb69553af1cf27bc
2011-05-02 16:29:42 -07:00
Chet Haase
7c212b2749 Merge "Line endcaps for AA lines are now antialiased." 2011-05-02 15:20:15 -07:00
Chet Haase
99585adeb4 Line endcaps for AA lines are now antialiased.
Also fixed other minor issues with AA and line rendering.

Change-Id: Icd4638d27c70e2ee0f28b5d9a2b97d8b29e8ac4d
2011-05-02 15:08:38 -07:00
Alex Sakhartchouk
d224c64a1f Merge "Moving renderscript GL code into the HAL This change affects - shaders - meshes - fonts - quad rendering" 2011-05-02 14:35:20 -07:00
Jason Sams
0be97d8b5e Temporarly disable auto-inbanding.
Change-Id: Ia83389c094914f0bb69bff8f6965ae445c89de07
2011-05-02 14:31:28 -07:00
Eino-Ville Talvala
3773eef4e3 Add an auto-exposure lock feature to the Camera API.
Adds a new camera parameter for locking auto-exposure to its current
value. Also adds a function for checking if auto-exposure lock is
supported by the current platform.

Hidden for now.

Change-Id: Id452371191ab220318ce2cb98b8ee91bdde9aab6
2011-05-02 09:36:06 -07:00
Alex Sakhartchouk
4a36b45c72 Moving renderscript GL code into the HAL
This change affects
 - shaders
 - meshes
 - fonts
 - quad rendering

Change-Id: I2a53acb4cd1fa8f4c6e67668f6ee969f3d7f7aa1
2011-04-29 16:49:08 -07:00
Jason Sams
eccf6c6483 Fix bug 4355588
With auto inbanding the fifo didn't reserve the correct size.
Caused failure on fifo wrap.

Change-Id: Ie78e7bef5286f68c6239f79ee2f284fd99bdacc3
2011-04-29 16:23:40 -07:00
Jason Sams
3ea208a843 Merge "Pipe rsa function though the RS api table." 2011-04-29 14:51:37 -07:00
Jason Sams
7da9ff5b97 Merge "Fix fifo size check code." 2011-04-29 14:50:09 -07:00
Jason Sams
c1f52d3f75 Fix fifo size check code.
Change-Id: If4a1874e34409e99c3fe63ff06e2b97e3369049d
2011-04-29 14:46:57 -07:00
Conley Owens
8ebf35589d Merge "Implement support for ALT and SHIFT modifiers" 2011-04-29 09:59:55 -07:00
Conley Owens
1ecd0a9b28 Merge "modify the device to enable to get the state as slide-open/slide-close." 2011-04-29 09:59:42 -07:00
Romain Guy
ad44445c77 Merge "New widget: TextureView Bug #4343984" 2011-04-28 18:47:01 -07:00