projects
/
org.ibex.core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
2003/10/19 02:21:59
[org.ibex.core.git]
/
src
/
org
/
xwt
/
plat
/
X11.cc
diff --git
a/src/org/xwt/plat/X11.cc
b/src/org/xwt/plat/X11.cc
index
3344622
..
cd5ce11
100644
(file)
--- a/
src/org/xwt/plat/X11.cc
+++ b/
src/org/xwt/plat/X11.cc
@@
-89,7
+89,7
@@
void org::xwt::plat::X11$X11PixelBuffer::fastDrawPicture(org::xwt::Picture* s,
}
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
}
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
- jint dx1, jint dy1, jint dx2, jint dy2, jint sx1, jint sy1, jint sx2, jint sy2) {
+ jint dx1, jint dy1, jint dx2, jint dy2, jint sx1, jint sy1, jint sx2, jint sy2, int rgb, int alphaOnly) {
org::xwt::plat::X11$X11Picture* source = (org::xwt::plat::X11$X11Picture*)s;
XImage* xi;
org::xwt::plat::X11$X11Picture* source = (org::xwt::plat::X11$X11Picture*)s;
XImage* xi;
@@
-123,6
+123,9
@@
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
int sourcepixel = sourcedata[source_x + source_y * source->getWidth()];
int alpha = (sourcepixel & 0xFF000000) >> 24;
int sourcepixel = sourcedata[source_x + source_y * source->getWidth()];
int alpha = (sourcepixel & 0xFF000000) >> 24;
+
+ // FEATURE: be smarter here; can we do something better for the alphaonly case?
+ if (alphaOnly) sourcepixel = rgb;
int source_red = (sourcepixel & 0x00FF0000) >> 16;
int source_green = (sourcepixel & 0x0000FF00) >> 8;
int source_blue = (sourcepixel & 0x000000FF);
int source_red = (sourcepixel & 0x00FF0000) >> 16;
int source_green = (sourcepixel & 0x0000FF00) >> 8;
int source_blue = (sourcepixel & 0x000000FF);