tBitmap Drawing

tBitmap Drawing

Post by D Whale » Thu, 03 Jul 2003 00:54:05



I have a strange problem with drawing to a tbitmap. It will work fine for a
while and then all of a sudden it just starts coming out all black. What's
wierd is the tBitmap gets created each time I draw on it so it couldn't be a
left over brush setting or such.

Function looks as such...
~~~~~~~~~~~~~~~~~
Function GetImage : tBitmap;
Begin
Result:=tBitmap.Create;
Result.Canvas.Brush.Style := bsClear;
Result.Height:=685;
Result.Width:=955;
// Do some Drawing here...
End;

The resulting Bitmap is freed elsewhere.

 
 
 

tBitmap Drawing

Post by Ignacio Vazque » Thu, 03 Jul 2003 00:57:38



Quote:> Result.Canvas.Brush.Style := bsClear;

I don't see any other properties of the brush being set. Try creating your
own brush at startup and use that each time.

Cheers,
  Ignacio

 
 
 

tBitmap Drawing

Post by D Whale » Thu, 03 Jul 2003 01:07:12


Would the brush not be set to a default brush when I create the Bitmap? If I
create a new tBitmap, it's Brush settings should not be affected by a
previous bitmap, correct?
 
 
 

tBitmap Drawing

Post by Ignacio Vazque » Thu, 03 Jul 2003 03:34:45



Quote:> Would the brush not be set to a default brush when I create the Bitmap? If
I
> create a new tBitmap, it's Brush settings should not be affected by a
> previous bitmap, correct?

You would hope so, but it's better to not take chances.

Cheers,
  Ignacio

 
 
 

1. Draw TBitmap XOR

I've got a problem with dragging a monochrome TBitmap across a TCanvas.
Here's my situation:
I am using the Canvas->StretchDraw method to draw the bitmap on the
canvas.
The Canvas' color is clWhite.
The bitmap has it's Transparent property set to true and
TransparentColor is set to clWhite.
Is it possible to draw the bitmap in XOR mode?

Thanks.
Patrick Rotsaert.

2. Materials Rendering

3. Draw TPanel in TBitmap

4. URL links in Pagemaker

5. out of system resource when drawing on TBitmap

6. WANTED!!!! Graphic Artists and Bitmap Art

7. How to draw an ellipse to a TBitmap?

8. how do I create a template in ps 7.0

9. Problem drawing transparent TBitmap on a TImage...

10. Drawing on a TBitmap?

11. OpenGL drawing to TBitmap

12. TBitmap.ScanLine and Canvas.Draw

13. Drawing into the TBitmap without canvas using ?