diff options
author | Jesse Hall <jessehall@google.com> | 2012-07-31 14:29:00 -0700 |
---|---|---|
committer | Jamie Gennis <jgennis@google.com> | 2012-08-07 12:26:59 -0700 |
commit | f9d6cd7dee62789b220033c926c87deab8991bde (patch) | |
tree | 04a2074b5b835b43c898c8182f74a98fb42b1a24 /modules/hwcomposer | |
parent | 5d64b230dc7c262575dd790299cfb667af66e014 (diff) | |
download | hardware_libhardware-f9d6cd7dee62789b220033c926c87deab8991bde.zip hardware_libhardware-f9d6cd7dee62789b220033c926c87deab8991bde.tar.gz hardware_libhardware-f9d6cd7dee62789b220033c926c87deab8991bde.tar.bz2 |
Add multi-display and flip fence to HWC
Change-Id: I3b0446050648e2b386ffb32976c9943b6fd9793d
Diffstat (limited to 'modules/hwcomposer')
-rw-r--r-- | modules/hwcomposer/hwcomposer.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/modules/hwcomposer/hwcomposer.cpp b/modules/hwcomposer/hwcomposer.cpp index 0e49e4c..f0a5512 100644 --- a/modules/hwcomposer/hwcomposer.cpp +++ b/modules/hwcomposer/hwcomposer.cpp @@ -67,26 +67,26 @@ static void dump_layer(hwc_layer_1_t const* l) { l->displayFrame.bottom); } -static int hwc_prepare(hwc_composer_device_1_t *dev, hwc_layer_list_1_t* list) { - if (list && (list->flags & HWC_GEOMETRY_CHANGED)) { - for (size_t i=0 ; i<list->numHwLayers ; i++) { +static int hwc_prepare(hwc_composer_device_1_t *dev, + size_t numDisplays, hwc_display_contents_1_t** displays) { + if (displays && (displays[0]->flags & HWC_GEOMETRY_CHANGED)) { + for (size_t i=0 ; i<displays[0]->numHwLayers ; i++) { //dump_layer(&list->hwLayers[i]); - list->hwLayers[i].compositionType = HWC_FRAMEBUFFER; + displays[0]->hwLayers[i].compositionType = HWC_FRAMEBUFFER; } } return 0; } static int hwc_set(hwc_composer_device_1_t *dev, - hwc_display_t dpy, - hwc_surface_t sur, - hwc_layer_list_1_t* list) + size_t numDisplays, hwc_display_contents_1_t** displays) { //for (size_t i=0 ; i<list->numHwLayers ; i++) { // dump_layer(&list->hwLayers[i]); //} - EGLBoolean sucess = eglSwapBuffers((EGLDisplay)dpy, (EGLSurface)sur); + EGLBoolean sucess = eglSwapBuffers((EGLDisplay)displays[0]->dpy, + (EGLSurface)displays[0]->sur); if (!sucess) { return HWC_EGL_ERROR; } |