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/29 03:48:15
[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
bb250e5
..
ca45618
100644
(file)
--- a/
src/org/xwt/plat/X11.cc
+++ b/
src/org/xwt/plat/X11.cc
@@
-78,7
+78,7
@@
void org::xwt::plat::X11$X11PixelBuffer::fastDrawPicture(org::xwt::Picture* s,
}
XCopyArea(display,
*((Pixmap*)source->doublebuf->pm), (*((Pixmap*)pm)), (*((GC*)clipped_gc)),
}
XCopyArea(display,
*((Pixmap*)source->doublebuf->pm), (*((Pixmap*)pm)), (*((GC*)clipped_gc)),
- cx1 - dx, cy2 - dy, cx2 - cx1, cy2 - cy1, cx1, cx2);
+ cx1 - dx, cy1 - dy, cx2 - cx1, cy2 - cy1, cx1, cy1);
}
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
}
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
@@
-111,14
+111,13
@@
void org::xwt::plat::X11$X11PixelBuffer::slowDrawPicture(org::xwt::Picture* s,
char* current_pixel = (xi->data + y * xi->bytes_per_line) +
(shared_pixmap ? cx1 * (xi->bits_per_pixel / 8) : - 1 * cy1 * xi->bytes_per_line);
char* current_pixel = (xi->data + y * xi->bytes_per_line) +
(shared_pixmap ? cx1 * (xi->bits_per_pixel / 8) : - 1 * cy1 * xi->bytes_per_line);
- for(int x=cx1; x < cx1; x++, current_pixel += xi->bits_per_pixel / 8) {
+ for(int x=cx1; x < cx2; x++, current_pixel += xi->bits_per_pixel / 8) {
int source_x = x - dx;
int source_y = y - dy;
int source_x = x - dx;
int source_y = y - dy;
+ // FEATURE: be smarter here; can we do something better for the alphaonly case?
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;
if (alphaOnly) sourcepixel = rgb;
int source_red = (sourcepixel & 0x00FF0000) >> 16;
int source_green = (sourcepixel & 0x0000FF00) >> 8;