summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMathias Agopian <mathias@google.com>2010-05-28 14:22:23 -0700
committerMathias Agopian <mathias@google.com>2010-05-28 17:19:16 -0700
commit770492cb2b19f6a36ad748cd05fbedfbb9a67dfa (patch)
tree3c87a789492e52b3c26b1de9608f42690b86c2cd /include
parentcdfd5fe2c89a30a31f9de5a5481e8997f014a89b (diff)
downloadframeworks_base-770492cb2b19f6a36ad748cd05fbedfbb9a67dfa.zip
frameworks_base-770492cb2b19f6a36ad748cd05fbedfbb9a67dfa.tar.gz
frameworks_base-770492cb2b19f6a36ad748cd05fbedfbb9a67dfa.tar.bz2
more clean-up in preparation of bigger changes
the most important change here is the renaming of ISurfaceFlingerClient to ISurfaceComposerClient Change-Id: I94e18b0417f50e06f21377446639c61f65f959b3
Diffstat (limited to 'include')
-rw-r--r--include/private/surfaceflinger/SharedBufferStack.h3
-rw-r--r--include/surfaceflinger/ISurface.h14
-rw-r--r--include/surfaceflinger/ISurfaceComposer.h4
-rw-r--r--include/surfaceflinger/ISurfaceComposerClient.h (renamed from include/surfaceflinger/ISurfaceFlingerClient.h)22
-rw-r--r--include/surfaceflinger/Surface.h4
-rw-r--r--include/surfaceflinger/SurfaceComposerClient.h4
6 files changed, 32 insertions, 19 deletions
diff --git a/include/private/surfaceflinger/SharedBufferStack.h b/include/private/surfaceflinger/SharedBufferStack.h
index b859e78..dcce25e 100644
--- a/include/private/surfaceflinger/SharedBufferStack.h
+++ b/include/private/surfaceflinger/SharedBufferStack.h
@@ -136,9 +136,7 @@ class SharedClient
public:
SharedClient();
~SharedClient();
-
status_t validate(size_t token) const;
- uint32_t getIdentity(size_t token) const;
private:
friend class SharedBufferBase;
@@ -160,6 +158,7 @@ public:
int32_t identity);
~SharedBufferBase();
status_t getStatus() const;
+ int32_t getIdentity() const;
size_t getFrontBuffer() const;
String8 dump(char const* prefix) const;
diff --git a/include/surfaceflinger/ISurface.h b/include/surfaceflinger/ISurface.h
index 18e7950..ddbe03d 100644
--- a/include/surfaceflinger/ISurface.h
+++ b/include/surfaceflinger/ISurface.h
@@ -53,10 +53,24 @@ protected:
public:
DECLARE_META_INTERFACE(Surface);
+ /*
+ * requests a new buffer for the given index. If w, h, or format are
+ * null the buffer is created with the parameters assigned to the
+ * surface it is bound to. Otherwise the buffer's parameters are
+ * set to those specified.
+ */
virtual sp<GraphicBuffer> requestBuffer(int bufferIdx,
uint32_t w, uint32_t h, uint32_t format, uint32_t usage) = 0;
+
+ /*
+ * sets the number of buffers dequeuable for this surface.
+ */
virtual status_t setBufferCount(int bufferCount) = 0;
+ // ------------------------------------------------------------------------
+ // Deprecated...
+ // ------------------------------------------------------------------------
+
class BufferHeap {
public:
enum {
diff --git a/include/surfaceflinger/ISurfaceComposer.h b/include/surfaceflinger/ISurfaceComposer.h
index d1e7785..3271cfd 100644
--- a/include/surfaceflinger/ISurfaceComposer.h
+++ b/include/surfaceflinger/ISurfaceComposer.h
@@ -27,7 +27,7 @@
#include <ui/PixelFormat.h>
-#include <surfaceflinger/ISurfaceFlingerClient.h>
+#include <surfaceflinger/ISurfaceComposerClient.h>
namespace android {
// ----------------------------------------------------------------------------
@@ -86,7 +86,7 @@ public:
* ACCESS_SURFACE_FLINGER permission
*/
- virtual sp<ISurfaceFlingerClient> createConnection() = 0;
+ virtual sp<ISurfaceComposerClient> createConnection() = 0;
/* retrieve the control block */
virtual sp<IMemoryHeap> getCblk() const = 0;
diff --git a/include/surfaceflinger/ISurfaceFlingerClient.h b/include/surfaceflinger/ISurfaceComposerClient.h
index c96432f..b2a4766 100644
--- a/include/surfaceflinger/ISurfaceFlingerClient.h
+++ b/include/surfaceflinger/ISurfaceComposerClient.h
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-#ifndef ANDROID_SF_ISURFACE_FLINGER_CLIENT_H
-#define ANDROID_SF_ISURFACE_FLINGER_CLIENT_H
+#ifndef ANDROID_SF_ISURFACE_COMPOSER_CLIENT_H
+#define ANDROID_SF_ISURFACE_COMPOSER_CLIENT_H
#include <stdint.h>
#include <sys/types.h>
@@ -26,7 +26,7 @@
#include <binder/IInterface.h>
#include <ui/PixelFormat.h>
-
+
#include <surfaceflinger/ISurface.h>
namespace android {
@@ -42,10 +42,10 @@ typedef int32_t DisplayID;
class layer_state_t;
-class ISurfaceFlingerClient : public IInterface
+class ISurfaceComposerClient : public IInterface
{
-public:
- DECLARE_META_INTERFACE(SurfaceFlingerClient);
+public:
+ DECLARE_META_INTERFACE(SurfaceComposerClient);
struct surface_data_t {
int32_t token;
@@ -56,21 +56,21 @@ public:
status_t readFromParcel(const Parcel& parcel);
status_t writeToParcel(Parcel* parcel) const;
};
-
+
virtual sp<IMemoryHeap> getControlBlock() const = 0;
/*
* Requires ACCESS_SURFACE_FLINGER permission
*/
virtual sp<ISurface> createSurface( surface_data_t* data,
- int pid,
+ int pid,
const String8& name,
DisplayID display,
uint32_t w,
uint32_t h,
PixelFormat format,
uint32_t flags) = 0;
-
+
/*
* Requires ACCESS_SURFACE_FLINGER permission
*/
@@ -84,7 +84,7 @@ public:
// ----------------------------------------------------------------------------
-class BnSurfaceFlingerClient : public BnInterface<ISurfaceFlingerClient>
+class BnSurfaceComposerClient : public BnInterface<ISurfaceComposerClient>
{
public:
virtual status_t onTransact( uint32_t code,
@@ -97,4 +97,4 @@ public:
}; // namespace android
-#endif // ANDROID_SF_ISURFACE_FLINGER_CLIENT_H
+#endif // ANDROID_SF_ISURFACE_COMPOSER_CLIENT_H
diff --git a/include/surfaceflinger/Surface.h b/include/surfaceflinger/Surface.h
index 33269cb..2957970 100644
--- a/include/surfaceflinger/Surface.h
+++ b/include/surfaceflinger/Surface.h
@@ -28,7 +28,7 @@
#include <ui/egl/android_natives.h>
#include <surfaceflinger/ISurface.h>
-#include <surfaceflinger/ISurfaceFlingerClient.h>
+#include <surfaceflinger/ISurfaceComposerClient.h>
#define ANDROID_VIEW_SURFACE_JNI_ID "mNativeSurface"
@@ -108,7 +108,7 @@ private:
SurfaceControl(
const sp<SurfaceComposerClient>& client,
const sp<ISurface>& surface,
- const ISurfaceFlingerClient::surface_data_t& data,
+ const ISurfaceComposerClient::surface_data_t& data,
uint32_t w, uint32_t h, PixelFormat format, uint32_t flags);
~SurfaceControl();
diff --git a/include/surfaceflinger/SurfaceComposerClient.h b/include/surfaceflinger/SurfaceComposerClient.h
index 102aebc..8e28a81 100644
--- a/include/surfaceflinger/SurfaceComposerClient.h
+++ b/include/surfaceflinger/SurfaceComposerClient.h
@@ -149,7 +149,7 @@ private:
// these don't need to be protected because they never change
// after assignment
status_t mStatus;
- sp<ISurfaceFlingerClient> mClient;
+ sp<ISurfaceComposerClient> mClient;
};
// ---------------------------------------------------------------------------
@@ -161,7 +161,7 @@ class SurfaceClient : public RefBase
SharedClient* mControl;
sp<IMemoryHeap> mControlMemory;
sp<IBinder> mConnection;
- sp<ISurfaceComposer> mSignalServer;
+ sp<ISurfaceComposer> mComposerService;
void init(const sp<IBinder>& conn);
public:
explicit SurfaceClient(const sp<IBinder>& conn);