 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Martijn Guest
|
Posted: Tue Nov 23, 2004 7:53 am Post subject: StretchBlt doesn't do half-toning |
|
|
Hi,
I have the following problem: I use a TPaintBox on a ScrollBox
to display document pages. Each page is rendered to an in-
memory bitmap (1 bit per pixel, approx 600 dpi). When I use
BitBlt to copy the pixels to the PaintBox' Canvas->Handle all
looks good (but very BIG).
However, when I use StretchBlt to view a compressed version of
the (large) bitmap in the PaintBox, it looks awful. When I
preceed the StretchBlt with this call
SetStretchBltMode(PaintBox->Canvas->Handle, STRETCH_HALFTONE);
I would expect the image to show shades of grey (anti-aliasing),
but it doesn't.
What am I doing wrong?
NOTE: I use BCB6 on WinXP
|
|
| Back to top |
|
 |
Bruce Salzman Guest
|
Posted: Tue Nov 23, 2004 5:16 pm Post subject: Re: StretchBlt doesn't do half-toning |
|
|
| Quote: | I have the following problem: I use a TPaintBox on a ScrollBox
to display document pages. Each page is rendered to an in-
memory bitmap (1 bit per pixel, approx 600 dpi). When I use
BitBlt to copy the pixels to the PaintBox' Canvas->Handle all
looks good (but very BIG).
However, when I use StretchBlt to view a compressed version of
the (large) bitmap in the PaintBox, it looks awful. When I
preceed the StretchBlt with this call
SetStretchBltMode(PaintBox->Canvas->Handle, STRETCH_HALFTONE);
I would expect the image to show shades of grey (anti-aliasing),
but it doesn't.
|
I wouldn't expect STRETCH_HALFTONE to work with a monochrome (1bpp)
bitmap. What happens if you use one of the other modes?
Regards,
Bruce
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|