summaryrefslogtreecommitdiff
path: root/libcopybit/copybit.h
diff options
context:
space:
mode:
Diffstat (limited to 'libcopybit/copybit.h')
-rw-r--r--libcopybit/copybit.h33
1 files changed, 30 insertions, 3 deletions
diff --git a/libcopybit/copybit.h b/libcopybit/copybit.h
index c14af74c..5adc433d 100644
--- a/libcopybit/copybit.h
+++ b/libcopybit/copybit.h
@@ -1,5 +1,9 @@
/*
* Copyright (C) 2008 The Android Open Source Project
+ * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
+ *
+ * Not a Contribution, Apache license notifications and license are retained
+ * for attribution purposes only.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -67,9 +71,8 @@ enum {
/* blurs the copied bitmap. The amount of blurring cannot be changed
* at this time. */
COPYBIT_BLUR = 5,
- /* Informs the copybit that the source and destination contains
- premultiplied alpha */
- COPYBIT_PREMULTIPLIED_ALPHA = 6,
+ /* Blend mode */
+ COPYBIT_BLEND_MODE = 6,
/* FB width */
COPYBIT_FRAMEBUFFER_WIDTH = 7,
/* FB height */
@@ -96,6 +99,20 @@ enum {
COPYBIT_ENABLE = 1
};
+/*
+ * copybit blending values. same as HWC blending values
+ */
+enum {
+ /* no blending */
+ COPYBIT_BLENDING_NONE = 0x0100,
+
+ /* ONE / ONE_MINUS_SRC_ALPHA */
+ COPYBIT_BLENDING_PREMULT = 0x0105,
+
+ /* SRC_ALPHA / ONE_MINUS_SRC_ALPHA */
+ COPYBIT_BLENDING_COVERAGE = 0x0405
+};
+
/* use get_static_info() to query static informations about the hardware */
enum {
/* Maximum amount of minification supported by the hardware*/
@@ -213,6 +230,16 @@ struct copybit_device_t {
struct copybit_rect_t const *dst_rect,
struct copybit_rect_t const *src_rect,
struct copybit_region_t const *region);
+
+ /**
+ * Execute the completion of the copybit draw operation.
+ *
+ * @param dev from open
+ *
+ * @return 0 if successful
+ */
+ int (*finish)(struct copybit_device_t *dev);
+
};