summaryrefslogtreecommitdiff
path: root/src/Fl_Bitmap.cxx
diff options
context:
space:
mode:
authorMichael R Sweet <michael.r.sweet@gmail.com>2001-11-24 02:46:19 +0000
committerMichael R Sweet <michael.r.sweet@gmail.com>2001-11-24 02:46:19 +0000
commit70abac1b8b995dc78ec312eb52f8724161b11b75 (patch)
tree4bf4d24e190a2a49e98c8fe3fdbecabe8c9cd2fa /src/Fl_Bitmap.cxx
parent4087b8cd9a139664420468c57489cae73c8b830a (diff)
Fix bugs in copy() methods.
Add Fl_Shared_Image class, with get() and release() methods. Update Fl_Help_View to use Fl_Shared_Image class. Update image demo to accept a filename, and to use the Fl_Shared_Image class. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1714 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Bitmap.cxx')
-rw-r--r--src/Fl_Bitmap.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Fl_Bitmap.cxx b/src/Fl_Bitmap.cxx
index 304f16029..f57f35256 100644
--- a/src/Fl_Bitmap.cxx
+++ b/src/Fl_Bitmap.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.5 2001/11/23 12:06:36 easysw Exp $"
+// "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.6 2001/11/24 02:46:19 easysw Exp $"
//
// Bitmap drawing routines for the Fast Light Tool Kit (FLTK).
//
@@ -242,8 +242,8 @@ Fl_Image *Fl_Bitmap::copy(int W, int H) {
memset(new_array, 0, H * (W + 7) / 8);
// Scale the image using a nearest-neighbor algorithm...
- for (dy = h(), sy = 0, yerr = H / 2, new_ptr = new_array; dy > 0; dy --) {
- for (dx = w(), xerr = W / 2, old_ptr = array + sy * (w() + 7) / 8, sx = 0, new_bit = 128;
+ for (dy = H, sy = 0, yerr = H / 2, new_ptr = new_array; dy > 0; dy --) {
+ for (dx = W, xerr = W / 2, old_ptr = array + sy * (w() + 7) / 8, sx = 0, new_bit = 128;
dx > 0;
dx --) {
old_bit = 128 >> (sx & 7);
@@ -278,5 +278,5 @@ Fl_Image *Fl_Bitmap::copy(int W, int H) {
}
//
-// End of "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.5 2001/11/23 12:06:36 easysw Exp $".
+// End of "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.6 2001/11/24 02:46:19 easysw Exp $".
//