Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9906d2e2 authored by Mathias Agopian's avatar Mathias Agopian Committed by Android (Google) Code Review
Browse files

Merge "SF transactions are now O(1) wrt IPC instead of O(N)."

parents 4ea52aea 2df788fb
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -568,10 +568,10 @@ int main(int argc, char **argv) {
        CHECK(control != NULL);
        CHECK(control->isValid());

        CHECK_EQ(composerClient->openTransaction(), (status_t)OK);
        SurfaceComposerClient::openGlobalTransaction();
        CHECK_EQ(control->setLayer(30000), (status_t)OK);
        CHECK_EQ(control->show(), (status_t)OK);
        CHECK_EQ(composerClient->closeTransaction(), (status_t)OK);
        SurfaceComposerClient::closeGlobalTransaction();

        surface = control->getSurface();
        CHECK(surface != NULL);
+2 −2
Original line number Diff line number Diff line
@@ -865,10 +865,10 @@ int main(int argc, char **argv) {
            CHECK(control != NULL);
            CHECK(control->isValid());

            CHECK_EQ(composerClient->openTransaction(), (status_t)OK);
            SurfaceComposerClient::openGlobalTransaction();
            CHECK_EQ(control->setLayer(30000), (status_t)OK);
            CHECK_EQ(control->show(), (status_t)OK);
            CHECK_EQ(composerClient->closeTransaction(), (status_t)OK);
            SurfaceComposerClient::closeGlobalTransaction();

            gSurface = control->getSurface();
            CHECK(gSurface != NULL);
+2 −2
Original line number Diff line number Diff line
@@ -305,10 +305,10 @@ int main(int argc, char **argv) {
    CHECK(control != NULL);
    CHECK(control->isValid());

    CHECK_EQ(composerClient->openTransaction(), (status_t)OK);
    SurfaceComposerClient::openGlobalTransaction();
    CHECK_EQ(control->setLayer(30000), (status_t)OK);
    CHECK_EQ(control->show(), (status_t)OK);
    CHECK_EQ(composerClient->closeTransaction(), (status_t)OK);
    SurfaceComposerClient::closeGlobalTransaction();

    sp<Surface> surface = control->getSurface();
    CHECK(surface != NULL);
+8 −0
Original line number Diff line number Diff line
@@ -29,6 +29,7 @@
namespace android {

class Parcel;
class ISurfaceComposerClient;

struct layer_state_t {

@@ -68,6 +69,13 @@ struct layer_state_t {
            Region          transparentRegion;
};

struct ComposerState {
    sp<ISurfaceComposerClient> client;
    layer_state_t state;
    status_t    write(Parcel& output) const;
    status_t    read(const Parcel& input);
};

}; // namespace android

#endif // ANDROID_SF_LAYER_STATE_H